attributeValueString returns the string form of a SAML AttributeValue. Some attributes, such as eduPersonTargetedID, carry a element instead of text content. For those the NameID's value is returned; the AttributeValue's own character data is then only (possibly empty) whitespace arou
(value saml.AttributeValue)
| 146 | // AttributeValue's own character data is then only (possibly empty) |
| 147 | // whitespace around the child element. |
| 148 | func attributeValueString(value saml.AttributeValue) string { |
| 149 | if value.NameID != nil { |
| 150 | return value.NameID.Value |
| 151 | } |
| 152 | return value.Value |
| 153 | } |
| 154 | |
| 155 | // Encode returns a serialized version of the Session. |
| 156 | // |