@@ -14,7 +14,6 @@ |
||
| 14 | 14 | * long as it does not already exist in the output directory. |
| 15 | 15 | * |
| 16 | 16 | */ |
| 17 | -class TerritoryQuery extends BaseTerritoryQuery |
|
| 18 | -{ |
|
| 17 | +class TerritoryQuery extends BaseTerritoryQuery { |
|
| 19 | 18 | |
| 20 | 19 | } // TerritoryQuery |
@@ -14,7 +14,6 @@ |
||
| 14 | 14 | * long as it does not already exist in the output directory. |
| 15 | 15 | * |
| 16 | 16 | */ |
| 17 | -class UserGroup extends BaseUserGroup |
|
| 18 | -{ |
|
| 17 | +class UserGroup extends BaseUserGroup { |
|
| 19 | 18 | |
| 20 | 19 | } |
@@ -14,7 +14,6 @@ |
||
| 14 | 14 | * long as it does not already exist in the output directory. |
| 15 | 15 | * |
| 16 | 16 | */ |
| 17 | -class UserGroupQuery extends BaseUserGroupQuery |
|
| 18 | -{ |
|
| 17 | +class UserGroupQuery extends BaseUserGroupQuery { |
|
| 19 | 18 | |
| 20 | 19 | } // UserGroupQuery |
@@ -14,7 +14,6 @@ |
||
| 14 | 14 | * long as it does not already exist in the output directory. |
| 15 | 15 | * |
| 16 | 16 | */ |
| 17 | -class UserQuery extends BaseUserQuery |
|
| 18 | -{ |
|
| 17 | +class UserQuery extends BaseUserQuery { |
|
| 19 | 18 | |
| 20 | 19 | } // UserQuery |
@@ -68,17 +68,17 @@ |
||
| 68 | 68 | |
| 69 | 69 | public function getKeekoPackage($type) { |
| 70 | 70 | switch ($type) { |
| 71 | - case 'app': |
|
| 72 | - if ($this->app === null) { |
|
| 73 | - $this->app = new AppSchema($this->package); |
|
| 74 | - } |
|
| 75 | - return $this->app; |
|
| 71 | + case 'app': |
|
| 72 | + if ($this->app === null) { |
|
| 73 | + $this->app = new AppSchema($this->package); |
|
| 74 | + } |
|
| 75 | + return $this->app; |
|
| 76 | 76 | |
| 77 | - case 'module': |
|
| 78 | - if ($this->module === null) { |
|
| 79 | - $this->module = new ModuleSchema($this->package); |
|
| 80 | - } |
|
| 81 | - return $this->module; |
|
| 77 | + case 'module': |
|
| 78 | + if ($this->module === null) { |
|
| 79 | + $this->module = new ModuleSchema($this->package); |
|
| 80 | + } |
|
| 81 | + return $this->module; |
|
| 82 | 82 | } |
| 83 | 83 | } |
| 84 | 84 | } |
@@ -10,7 +10,7 @@ |
||
| 10 | 10 | * @return string |
| 11 | 11 | */ |
| 12 | 12 | public static function toStudlyCase($input) { |
| 13 | - return ucfirst(preg_replace_callback('/([A-Z-_][a-z]+)/', function ($matches) { |
|
| 13 | + return ucfirst(preg_replace_callback('/([A-Z-_][a-z]+)/', function($matches) { |
|
| 14 | 14 | return ucfirst(str_replace([ |
| 15 | 15 | '-', |
| 16 | 16 | '_' |
@@ -1,9 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace keeko\core\installer; |
| 3 | 3 | |
| 4 | -use Composer\DependencyResolver\Operation\InstallOperation; |
|
| 5 | -use Composer\DependencyResolver\Operation\UninstallOperation; |
|
| 6 | -use Composer\DependencyResolver\Operation\UpdateOperation; |
|
| 7 | 4 | use Composer\Package\PackageInterface; |
| 8 | 5 | use Composer\Script\PackageEvent; |
| 9 | 6 | |
@@ -59,14 +59,14 @@ |
||
| 59 | 59 | */ |
| 60 | 60 | private function getInstaller(PackageInterface $package) { |
| 61 | 61 | switch ($package->getType()) { |
| 62 | - case 'keeko-app': |
|
| 63 | - return new AppInstaller(); |
|
| 62 | + case 'keeko-app': |
|
| 63 | + return new AppInstaller(); |
|
| 64 | 64 | |
| 65 | - case 'keeko-module': |
|
| 66 | - return new ModuleInstaller(); |
|
| 65 | + case 'keeko-module': |
|
| 66 | + return new ModuleInstaller(); |
|
| 67 | 67 | |
| 68 | - default: |
|
| 69 | - return new DummyInstaller(); |
|
| 68 | + default: |
|
| 69 | + return new DummyInstaller(); |
|
| 70 | 70 | } |
| 71 | 71 | } |
| 72 | 72 | |
@@ -196,7 +196,7 @@ |
||
| 196 | 196 | |
| 197 | 197 | // firewall |
| 198 | 198 | $firewall = $this->getServiceContainer()->getFirewall(); |
| 199 | - $this->twig->addFunction(new Twig_SimpleFunction('hasPermission', function ($module, $action) use ($firewall) { |
|
| 199 | + $this->twig->addFunction(new Twig_SimpleFunction('hasPermission', function($module, $action) use ($firewall) { |
|
| 200 | 200 | return $firewall->hasPermission($module, $action); |
| 201 | 201 | })); |
| 202 | 202 | } |
@@ -238,23 +238,23 @@ |
||
| 238 | 238 | */ |
| 239 | 239 | private function getGroup($name) { |
| 240 | 240 | switch ($name) { |
| 241 | - case 'guest': |
|
| 242 | - if ($this->guestGroup === null) { |
|
| 243 | - $this->guestGroup = GroupQuery::create()->filterByIsGuest(true)->findOne(); |
|
| 244 | - } |
|
| 245 | - return $this->guestGroup; |
|
| 241 | + case 'guest': |
|
| 242 | + if ($this->guestGroup === null) { |
|
| 243 | + $this->guestGroup = GroupQuery::create()->filterByIsGuest(true)->findOne(); |
|
| 244 | + } |
|
| 245 | + return $this->guestGroup; |
|
| 246 | 246 | |
| 247 | - case 'user': |
|
| 248 | - if ($this->userGroup === null) { |
|
| 249 | - $this->userGroup = GroupQuery::create()->filterByIsDefault(true)->findOne(); |
|
| 250 | - } |
|
| 251 | - return $this->userGroup; |
|
| 247 | + case 'user': |
|
| 248 | + if ($this->userGroup === null) { |
|
| 249 | + $this->userGroup = GroupQuery::create()->filterByIsDefault(true)->findOne(); |
|
| 250 | + } |
|
| 251 | + return $this->userGroup; |
|
| 252 | 252 | |
| 253 | - case 'admin': |
|
| 254 | - if ($this->adminGroup === null) { |
|
| 255 | - $this->adminGroup = GroupQuery::create()->findOneById(3); |
|
| 256 | - } |
|
| 257 | - return $this->adminGroup; |
|
| 253 | + case 'admin': |
|
| 254 | + if ($this->adminGroup === null) { |
|
| 255 | + $this->adminGroup = GroupQuery::create()->findOneById(3); |
|
| 256 | + } |
|
| 257 | + return $this->adminGroup; |
|
| 258 | 258 | } |
| 259 | 259 | } |
| 260 | 260 | |