File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 77use Exception ;
88use InvalidArgumentException ;
99use SimpleSAML \Assert \Assert as BaseAssert ;
10+ use SimpleSAML \Assert \AssertionFailedException ;
1011use SimpleSAML \XML \Constants as C ;
1112
1213use function in_array ;
@@ -148,7 +149,7 @@ public static function allowedXPathFilter(
148149 // Check that all the function names we found are in the list of allowed function names
149150 foreach ($ matches [1 ] as $ match ) {
150151 if (!in_array ($ match , $ allowed_functions )) {
151- throw new InvalidArgumentException (sprintf (
152+ throw new AssertionFailedException (sprintf (
152153 $ message ?: '\'%s \' is not an allowed XPath function. ' ,
153154 $ match ,
154155 ));
@@ -171,7 +172,7 @@ public static function allowedXPathFilter(
171172 // Check that all the axes names we found are in the list of allowed axes names
172173 foreach ($ matches [1 ] as $ match ) {
173174 if (!in_array ($ match , $ allowed_axes )) {
174- throw new InvalidArgumentException (sprintf (
175+ throw new AssertionFailedException (sprintf (
175176 $ message ?: '\'%s \' is not an allowed XPath axis. ' ,
176177 $ match ,
177178 ));
You can’t perform that action at this time.
0 commit comments