From ef0ab83e2058bda2bcd813cc9e72e452c8a0da58 Mon Sep 17 00:00:00 2001 From: denisdulici Date: Mon, 6 Jan 2020 23:46:34 +0300 Subject: [PATCH] fixed tests --- overrides/akaunting/module/Commands/InstallCommand.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/overrides/akaunting/module/Commands/InstallCommand.php b/overrides/akaunting/module/Commands/InstallCommand.php index 849d8b7f4..3a12bdac5 100644 --- a/overrides/akaunting/module/Commands/InstallCommand.php +++ b/overrides/akaunting/module/Commands/InstallCommand.php @@ -112,6 +112,10 @@ class InstallCommand extends Command foreach ($roles as $role) { foreach ($permissions as $permission) { + if ($role->hasPermission($permission->name)) { + continue; + } + $role->attachPermission($permission); } }