We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4d31c9c commit b3cc7c4Copy full SHA for b3cc7c4
src/saml2/saml.py
@@ -166,11 +166,16 @@ def set_type(self, typ):
166
167
try:
168
self.extension_attributes[XSI_TYPE] = typ
169
- self.extension_attributes['xmlns:xs'] = XS_NAMESPACE
170
except AttributeError:
171
- self._extatt['xmlns:xs'] = XS_NAMESPACE
172
self._extatt[XSI_TYPE] = typ
173
+ if typ.startswith('xs:'):
+ try:
174
+ self.extension_attributes['xmlns:xs'] = XS_NAMESPACE
175
+ except AttributeError:
176
+ self._extatt['xmlns:xs'] = XS_NAMESPACE
177
+
178
179
def get_type(self):
180
181
return self.extension_attributes[XSI_TYPE]
0 commit comments