mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
BUGFIX Throwing an InvalidArgumentException without the new keyword results in a Fatal error
This commit is contained in:
parent
f546ab2a70
commit
ce5684c776
@ -26,7 +26,7 @@ class GenericTemplateGlobalProvider implements TemplateGlobalProvider {
|
|||||||
if(isset(self::$modules[$name])) {
|
if(isset(self::$modules[$name])) {
|
||||||
return self::$modules[$name];
|
return self::$modules[$name];
|
||||||
} else {
|
} else {
|
||||||
throw InvalidArgumentException(sprintf('%s is not a supported argument. Possible values: %s', $name, implode(', ', self::$modules)));
|
throw new InvalidArgumentException(sprintf('%s is not a supported argument. Possible values: %s', $name, implode(', ', self::$modules)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user