Skip to content

Commit 0f77cac

Browse files
committed
Map XAdES schemas correctly
1 parent 21b0441 commit 0f77cac

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

signxml/processor.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@
1818

1919
@lru_cache
2020
def get_schema(schema_file: str) -> etree.XMLSchema:
21-
schema_fh = importlib.resources.open_text("signxml.schemas", schema_file)
21+
pkg_name = "signxml.xades.schemas" if schema_file.startswith("XAdES") else "signxml.schemas"
22+
schema_fh = importlib.resources.open_text(pkg_name, schema_file)
2223
return etree.XMLSchema(etree.parse(schema_fh))
2324

2425

0 commit comments

Comments
 (0)