@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | |
16 | 16 | public function boot() |
17 | 17 | { |
18 | - $this->app['validator']->extend('LangRequired', function ($attribute, $value) { |
|
18 | + $this->app['validator']->extend('LangRequired', function($attribute, $value) { |
|
19 | 19 | $fields = $this->app['request']->all(); |
20 | 20 | $protocol = 'xe_lang_preprocessor://'; |
21 | 21 | $prefix = null; |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | } |
30 | 30 | |
31 | 31 | $locale = $this->app['xe.translator']->getLocale(); |
32 | - $name = $prefix . '/locale/' . $locale; |
|
32 | + $name = $prefix.'/locale/'.$locale; |
|
33 | 33 | $validator = null; |
34 | 34 | |
35 | 35 | foreach ($fields as $key => $val) { |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | |
52 | 52 | public function register() |
53 | 53 | { |
54 | - $this->app->singleton('xe.translator', function ($app) { |
|
54 | + $this->app->singleton('xe.translator', function($app) { |
|
55 | 55 | $debug = $app['config']['app.debug']; |
56 | 56 | $keyGen = $app['xe.keygen']; |
57 | 57 | $cache = new TransCache($app['cache']->driver('lang'), $debug); |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | */ |
63 | 63 | public function register() |
64 | 64 | { |
65 | - $this->app->bind('xe.media', function ($app) { |
|
65 | + $this->app->bind('xe.media', function($app) { |
|
66 | 66 | $config = $app['config']['xe.media']; |
67 | 67 | $proxyClass = $app['xe.interception']->proxy(MediaManager::class, 'XeMedia'); |
68 | 68 | $mediaManager = new $proxyClass($app['xe.storage'], new CommandFactory(), $config['thumbnail']); |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | $mediaManager->extend(Media::TYPE_IMAGE, new ImageHandler($app['xe.storage'])); |
71 | 71 | |
72 | 72 | $extensionName = isset($config['videoExtensionDefault']) ? $config['videoExtensionDefault'] : 'dummy'; |
73 | - $method = 'create' . ucfirst($extensionName) . 'Extension'; |
|
73 | + $method = 'create'.ucfirst($extensionName).'Extension'; |
|
74 | 74 | if (method_exists($this, $method) !== true) { |
75 | 75 | throw new \InvalidArgumentException( |
76 | 76 | sprintf('Unknown extension [%s]', $config['videoExtensionDefault']) |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | |
123 | 123 | private function registerEvent() |
124 | 124 | { |
125 | - intercept('XeStorage@remove', 'media.remove', function ($target, $file) { |
|
125 | + intercept('XeStorage@remove', 'media.remove', function($target, $file) { |
|
126 | 126 | |
127 | 127 | /** @var MediaManager $manager */ |
128 | 128 | $manager = $this->app['xe.media']; |
@@ -67,7 +67,7 @@ discard block |
||
67 | 67 | { |
68 | 68 | $this->app->singleton( |
69 | 69 | [RouteRepository::class => 'xe.router'], |
70 | - function ($app) { |
|
70 | + function($app) { |
|
71 | 71 | $repo = new DatabaseRouteRepository($app['config'], InstanceRoute::class); |
72 | 72 | |
73 | 73 | if (env('APP_DEBUG') != true) { |
@@ -130,12 +130,12 @@ discard block |
||
130 | 130 | */ |
131 | 131 | protected function registerSettingsMacro(Router $router) |
132 | 132 | { |
133 | - $manageMacro = function ($key, Closure $callback, $routeOptions = null) { |
|
133 | + $manageMacro = function($key, Closure $callback, $routeOptions = null) { |
|
134 | 134 | |
135 | 135 | $key = str_replace('.', '/', $key); |
136 | 136 | |
137 | 137 | $attributes = [ |
138 | - 'prefix' => config('xe.routing.settingsPrefix') . '/' . $key, |
|
138 | + 'prefix' => config('xe.routing.settingsPrefix').'/'.$key, |
|
139 | 139 | 'middleware' => ['settings'] |
140 | 140 | ]; |
141 | 141 | |
@@ -161,12 +161,12 @@ discard block |
||
161 | 161 | */ |
162 | 162 | protected function registerFixedMacro(Router $router) |
163 | 163 | { |
164 | - $fixedMacro = function ($key, Closure $callback, $routeOptions = null) { |
|
164 | + $fixedMacro = function($key, Closure $callback, $routeOptions = null) { |
|
165 | 165 | |
166 | 166 | $newKey = str_replace('@', '/', $key); |
167 | 167 | |
168 | 168 | $attributes = [ |
169 | - 'prefix' => config('xe.routing.fixedPrefix') . '/' . $newKey |
|
169 | + 'prefix' => config('xe.routing.fixedPrefix').'/'.$newKey |
|
170 | 170 | ]; |
171 | 171 | |
172 | 172 | if ($routeOptions !== null and is_array($routeOptions)) { |
@@ -192,7 +192,7 @@ discard block |
||
192 | 192 | protected function registerInstanceMacro(Router $router) |
193 | 193 | { |
194 | 194 | static $seq = 1; |
195 | - $instanceMacro = function ($key, Closure $callback, $routeOptions = null) use (&$seq) { |
|
195 | + $instanceMacro = function($key, Closure $callback, $routeOptions = null) use (&$seq) { |
|
196 | 196 | |
197 | 197 | $pattern = '{instanceGroup'.$seq++.'}'; |
198 | 198 | $attributes = [ |
@@ -206,7 +206,7 @@ discard block |
||
206 | 206 | $attributes = array_merge($attributes, $routeOptions); |
207 | 207 | |
208 | 208 | if (isset($routeOptions['middleware'])) { |
209 | - $attributes['middleware'] .= '|' . $routeOptions['middleware']; |
|
209 | + $attributes['middleware'] .= '|'.$routeOptions['middleware']; |
|
210 | 210 | } |
211 | 211 | } |
212 | 212 |
@@ -10,7 +10,7 @@ |
||
10 | 10 | |
11 | 11 | public function install() |
12 | 12 | { |
13 | - Schema::create('translation', function (Blueprint $table) { |
|
13 | + Schema::create('translation', function(Blueprint $table) { |
|
14 | 14 | $table->engine = "InnoDB"; |
15 | 15 | |
16 | 16 | $table->increments('id'); |
@@ -16,7 +16,7 @@ discard block |
||
16 | 16 | |
17 | 17 | public function install() |
18 | 18 | { |
19 | - Schema::create('menu', function (Blueprint $table) { |
|
19 | + Schema::create('menu', function(Blueprint $table) { |
|
20 | 20 | $table->engine = "InnoDB"; |
21 | 21 | |
22 | 22 | $table->string('id', 8); |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | $table->primary('id'); |
28 | 28 | }); |
29 | 29 | |
30 | - Schema::create('menuItem', function (Blueprint $table) { |
|
30 | + Schema::create('menuItem', function(Blueprint $table) { |
|
31 | 31 | $table->engine = "InnoDB"; |
32 | 32 | |
33 | 33 | $table->string('id', 8); |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | $table->primary('id'); |
46 | 46 | }); |
47 | 47 | |
48 | - Schema::create('menuTreePath', function (Blueprint $table) { |
|
48 | + Schema::create('menuTreePath', function(Blueprint $table) { |
|
49 | 49 | $table->engine = "InnoDB"; |
50 | 50 | |
51 | 51 | $table->increments('id'); |
@@ -192,8 +192,8 @@ discard block |
||
192 | 192 | { |
193 | 193 | /** @var ThemeHandler $themeHandler */ |
194 | 194 | $themeHandler = app('xe.theme'); |
195 | - $themeHandler->setThemeConfig('alice', 'mainMenu', $mainMenu ); |
|
196 | - $themeHandler->setThemeConfig('alice', 'subMenu', $mainMenu ); |
|
195 | + $themeHandler->setThemeConfig('alice', 'mainMenu', $mainMenu); |
|
196 | + $themeHandler->setThemeConfig('alice', 'subMenu', $mainMenu); |
|
197 | 197 | } |
198 | 198 | |
199 | 199 | /** |
@@ -28,6 +28,6 @@ |
||
28 | 28 | */ |
29 | 29 | $compiledPath = __DIR__.'/cache/compiled.php'; |
30 | 30 | |
31 | -if (file_exists($compiledPath)){ |
|
31 | +if (file_exists($compiledPath)) { |
|
32 | 32 | require $compiledPath; |
33 | 33 | } |
@@ -16,7 +16,7 @@ discard block |
||
16 | 16 | * XE에서 새로운 request가 생성될 때에는 이 ReqeustFactory는 사용되어 항상 Xpressengine\Http\Request를 생성하도록 한다 |
17 | 17 | */ |
18 | 18 | Request::setFactory( |
19 | - function ( |
|
19 | + function( |
|
20 | 20 | $query, |
21 | 21 | $request, |
22 | 22 | $attributes, |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | |
84 | 84 | $app->bind( |
85 | 85 | 'path.public', |
86 | - function () { |
|
86 | + function() { |
|
87 | 87 | return base_path(); |
88 | 88 | } |
89 | 89 | ); |
@@ -33,11 +33,11 @@ |
||
33 | 33 | Thumbnailer::setManager($manager); |
34 | 34 | $instance = new Thumbnailer(); |
35 | 35 | |
36 | - $imageContent = file_get_contents(__DIR__ . '/sample.png'); |
|
36 | + $imageContent = file_get_contents(__DIR__.'/sample.png'); |
|
37 | 37 | $mockCommand = m::mock('Xpressengine\Media\Commands\CommandInterface'); |
38 | 38 | |
39 | 39 | $mockCommand->shouldReceive('getName')->andReturn('letter'); |
40 | - $mockCommand->shouldReceive('setOriginDimension')->once()->with(m::on(function ($object) { |
|
40 | + $mockCommand->shouldReceive('setOriginDimension')->once()->with(m::on(function($object) { |
|
41 | 41 | return $object instanceof Dimension; |
42 | 42 | })); |
43 | 43 | $mockCommand->shouldReceive('getMethod')->andReturn('resize'); |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | $advisorStore = $proxy->getAdvisorCollection(); |
47 | 47 | |
48 | 48 | $advisor1 = new Advisor( |
49 | - 'ad1', 'Xpressengine\Tests\Interception\Document@insertDocument', function ($target, $title, $content) { |
|
49 | + 'ad1', 'Xpressengine\Tests\Interception\Document@insertDocument', function($target, $title, $content) { |
|
50 | 50 | return 'ad1('.$target($title, $content).')'; |
51 | 51 | } |
52 | 52 | ); |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | $advisor2 = new Advisor( |
56 | 56 | 'ad2', |
57 | 57 | ['Xpressengine\Tests\Interception\Document@insertDocument', 'Xpressengine\Tests\Interception\Document@checkInput'], |
58 | - function ($target, $title, $content) { |
|
58 | + function($target, $title, $content) { |
|
59 | 59 | if ($target->invokedMethod == 'insertDocument') { |
60 | 60 | return 'ad2('.$target($title, $content).')'; |
61 | 61 | } |
@@ -66,12 +66,12 @@ discard block |
||
66 | 66 | return [$title, $content]; |
67 | 67 | } |
68 | 68 | ); |
69 | - $advisorStore->put($advisor2, ['before'=>['ad1','ad3']]); |
|
69 | + $advisorStore->put($advisor2, ['before'=>['ad1', 'ad3']]); |
|
70 | 70 | |
71 | 71 | $advisor3 = new Advisor( |
72 | 72 | 'ad3', |
73 | 73 | 'Xpressengine\Tests\Interception\Document@checkInput', |
74 | - function ($target, $title, $content) { |
|
74 | + function($target, $title, $content) { |
|
75 | 75 | return ['modified '.$title.' by ad2', 'modified '.$content.' by ad2']; |
76 | 76 | }, |
77 | 77 | 'ad1' |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | new Advisor( |
94 | 94 | 'ad1', |
95 | 95 | 'Xpressengine\Tests\Interception\Document@add', |
96 | - function ($target, $obj) { |
|
96 | + function($target, $obj) { |
|
97 | 97 | $obj->title = 'modified '.$obj->title; |
98 | 98 | return $target($obj); |
99 | 99 | } |
@@ -114,7 +114,7 @@ discard block |
||
114 | 114 | |
115 | 115 | $advisor1 = new Advisor( |
116 | 116 | 'ad1', 'Xpressengine\Tests\Interception\Document@magicMethod', |
117 | - function ($target, $title, $content) { |
|
117 | + function($target, $title, $content) { |
|
118 | 118 | return 'ad1('.$target($title, $content).')'; |
119 | 119 | } |
120 | 120 | ); |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | |
123 | 123 | $advisor2 = new Advisor( |
124 | 124 | 'ad2', 'Xpressengine\Tests\Interception\Document@magicMethod', |
125 | - function ($target, $title, $content) { |
|
125 | + function($target, $title, $content) { |
|
126 | 126 | return 'ad2('.$target($title, $content).')'; |
127 | 127 | } |
128 | 128 | ); |