check code parameter in update-scopes method
This commit is contained in:
parent
f3db3fdb63
commit
a95ec22823
@ -88,6 +88,12 @@ trait Module
|
||||
*/
|
||||
public function integrationModulesUpdateScopes($code, array $requires)
|
||||
{
|
||||
if (empty($code)) {
|
||||
throw new \InvalidArgumentException(
|
||||
'Parameter `code` must be set'
|
||||
);
|
||||
}
|
||||
|
||||
if (!count($requires) || empty($requires['scopes'])) {
|
||||
throw new \InvalidArgumentException(
|
||||
'Parameter `requires` must contains a data & configuration `scopes` must be set'
|
||||
|
Loading…
Reference in New Issue
Block a user