@@ -4,10 +4,10 @@ |
||
4 | 4 | |
5 | 5 | use ICanBoogie; |
6 | 6 | |
7 | -$hooks = Hooks::class . '::'; |
|
7 | +$hooks = Hooks::class.'::'; |
|
8 | 8 | |
9 | 9 | return [ |
10 | 10 | |
11 | - ICanBoogie\Core::class . '::boot' => $hooks . 'on_core_boot' |
|
11 | + ICanBoogie\Core::class.'::boot' => $hooks.'on_core_boot' |
|
12 | 12 | |
13 | 13 | ]; |
@@ -2,7 +2,7 @@ discard block |
||
2 | 2 | |
3 | 3 | namespace Patron; |
4 | 4 | |
5 | -$hooks = Hooks::class . '::'; |
|
5 | +$hooks = Hooks::class.'::'; |
|
6 | 6 | |
7 | 7 | return [ |
8 | 8 | |
@@ -12,9 +12,9 @@ discard block |
||
12 | 12 | |
13 | 13 | 'template' => [ |
14 | 14 | |
15 | - $hooks . 'markup_template', [ |
|
15 | + $hooks.'markup_template', [ |
|
16 | 16 | |
17 | - 'name' => [ 'required' => true ] |
|
17 | + 'name' => ['required' => true] |
|
18 | 18 | |
19 | 19 | ], |
20 | 20 | |
@@ -24,9 +24,9 @@ discard block |
||
24 | 24 | |
25 | 25 | 'call-template' => [ |
26 | 26 | |
27 | - $hooks . 'markup_call_template', [ |
|
27 | + $hooks.'markup_call_template', [ |
|
28 | 28 | |
29 | - 'name' => [ 'required' => true ] |
|
29 | + 'name' => ['required' => true] |
|
30 | 30 | |
31 | 31 | ], |
32 | 32 | |
@@ -36,18 +36,18 @@ discard block |
||
36 | 36 | |
37 | 37 | 'decorate' => [ |
38 | 38 | |
39 | - $hooks . 'markup_decorate', [ |
|
39 | + $hooks.'markup_decorate', [ |
|
40 | 40 | |
41 | - 'with' => [ 'required' => true ] |
|
41 | + 'with' => ['required' => true] |
|
42 | 42 | |
43 | 43 | ] |
44 | 44 | ], |
45 | 45 | |
46 | 46 | 'foreach' => [ |
47 | 47 | |
48 | - $hooks . 'markup_foreach', [ |
|
48 | + $hooks.'markup_foreach', [ |
|
49 | 49 | |
50 | - 'in' => [ 'default' => 'this', 'expression' => true ], |
|
50 | + 'in' => ['default' => 'this', 'expression' => true], |
|
51 | 51 | 'as' => null |
52 | 52 | |
53 | 53 | ] |
@@ -55,10 +55,10 @@ discard block |
||
55 | 55 | |
56 | 56 | 'variable' => [ |
57 | 57 | |
58 | - $hooks . 'markup_variable', [ |
|
58 | + $hooks.'markup_variable', [ |
|
59 | 59 | |
60 | - 'name' => [ 'required' => true ], |
|
61 | - 'select' => [ 'expression' => true ] |
|
60 | + 'name' => ['required' => true], |
|
61 | + 'select' => ['expression' => true] |
|
62 | 62 | |
63 | 63 | ], |
64 | 64 | |
@@ -67,16 +67,16 @@ discard block |
||
67 | 67 | |
68 | 68 | 'with' => [ |
69 | 69 | |
70 | - $hooks . 'markup_with', [ |
|
70 | + $hooks.'markup_with', [ |
|
71 | 71 | |
72 | - 'select' => [ 'expression' => true ] |
|
72 | + 'select' => ['expression' => true] |
|
73 | 73 | |
74 | 74 | ] |
75 | 75 | ], |
76 | 76 | |
77 | 77 | 'choose' => [ |
78 | 78 | |
79 | - $hooks . 'markup_choose', [ |
|
79 | + $hooks.'markup_choose', [ |
|
80 | 80 | |
81 | 81 | |
82 | 82 | ], |
@@ -87,10 +87,10 @@ discard block |
||
87 | 87 | |
88 | 88 | 'if' => [ |
89 | 89 | |
90 | - $hooks . 'markup_if', [ |
|
90 | + $hooks.'markup_if', [ |
|
91 | 91 | |
92 | - 'test' => [ 'expression' => [ 'silent' => true ] ], |
|
93 | - 'select' => [ 'expression' => [ 'silent' => true ] ], |
|
92 | + 'test' => ['expression' => ['silent' => true]], |
|
93 | + 'select' => ['expression' => ['silent' => true]], |
|
94 | 94 | 'equals' => null |
95 | 95 | |
96 | 96 | ], |
@@ -101,9 +101,9 @@ discard block |
||
101 | 101 | |
102 | 102 | 'translate' => [ |
103 | 103 | |
104 | - $hooks . 'markup_translate', [ |
|
104 | + $hooks.'markup_translate', [ |
|
105 | 105 | |
106 | - 'native' => [ 'required' => true ] |
|
106 | + 'native' => ['required' => true] |
|
107 | 107 | |
108 | 108 | ] |
109 | 109 | ], |
@@ -114,13 +114,13 @@ discard block |
||
114 | 114 | |
115 | 115 | 'pager' => [ |
116 | 116 | |
117 | - $hooks . 'markup_pager', [ |
|
117 | + $hooks.'markup_pager', [ |
|
118 | 118 | |
119 | 119 | 'count' => null, |
120 | 120 | 'page' => null, |
121 | 121 | 'limit' => null, |
122 | 122 | 'with' => null, |
123 | - 'range' => [ 'expression' => true ], |
|
123 | + 'range' => ['expression' => true], |
|
124 | 124 | 'noarrows' => false |
125 | 125 | |
126 | 126 | ] |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | |
129 | 129 | 'document:css' => [ |
130 | 130 | |
131 | - $hooks . 'markup_document_css', [ |
|
131 | + $hooks.'markup_document_css', [ |
|
132 | 132 | |
133 | 133 | 'href' => null, |
134 | 134 | 'weight' => 100 |
@@ -138,7 +138,7 @@ discard block |
||
138 | 138 | |
139 | 139 | 'document:js' => [ |
140 | 140 | |
141 | - $hooks . 'markup_document_js', [ |
|
141 | + $hooks.'markup_document_js', [ |
|
142 | 142 | |
143 | 143 | 'href' => null, |
144 | 144 | 'weight' => 100 |
@@ -178,7 +178,7 @@ |
||
178 | 178 | |
179 | 179 | 'markdown' => function($text) { |
180 | 180 | |
181 | - require_once dirname(__DIR__) . '/lib/textmark/textmark.php'; |
|
181 | + require_once dirname(__DIR__).'/lib/textmark/textmark.php'; |
|
182 | 182 | |
183 | 183 | return \Markdown($text); |
184 | 184 |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | |
21 | 21 | if (!$markups) |
22 | 22 | { |
23 | - $markups = new MarkupCollection(require __DIR__ . '/../res' . DIRECTORY_SEPARATOR . 'markups.php'); |
|
23 | + $markups = new MarkupCollection(require __DIR__.'/../res'.DIRECTORY_SEPARATOR.'markups.php'); |
|
24 | 24 | |
25 | 25 | new MarkupCollection\AlterEvent($markups); |
26 | 26 | } |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | |
38 | 38 | if (!$functions) |
39 | 39 | { |
40 | - $functions = new FunctionCollection(require __DIR__ . '/../res' . DIRECTORY_SEPARATOR . 'functions.php'); |
|
40 | + $functions = new FunctionCollection(require __DIR__.'/../res'.DIRECTORY_SEPARATOR.'functions.php'); |
|
41 | 41 | |
42 | 42 | new FunctionCollection\AlterEvent($functions); |
43 | 43 | } |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | |
47 | 47 | if (!$f) |
48 | 48 | { |
49 | - throw new FunctionNotDefined([ $method, $this ]); |
|
49 | + throw new FunctionNotDefined([$method, $this]); |
|
50 | 50 | } |
51 | 51 | |
52 | 52 | return call_user_func_array($f, $arguments); |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | { |
78 | 78 | if (!$this->offsetExists($name)) |
79 | 79 | { |
80 | - throw new FunctionNotDefined([ $name, $this ]); |
|
80 | + throw new FunctionNotDefined([$name, $this]); |
|
81 | 81 | } |
82 | 82 | |
83 | 83 | return $this->collection[$name]; |
@@ -118,21 +118,21 @@ discard block |
||
118 | 118 | return $this->collection[$name]; |
119 | 119 | } |
120 | 120 | |
121 | - $try = 'ICanBoogie\\' . $name; |
|
121 | + $try = 'ICanBoogie\\'.$name; |
|
122 | 122 | |
123 | 123 | if (function_exists($try)) |
124 | 124 | { |
125 | 125 | return $try; |
126 | 126 | } |
127 | 127 | |
128 | - $try = 'ICanBoogie\I18n\\' . $name; |
|
128 | + $try = 'ICanBoogie\I18n\\'.$name; |
|
129 | 129 | |
130 | 130 | if (function_exists($try)) |
131 | 131 | { |
132 | 132 | return $try; |
133 | 133 | } |
134 | 134 | |
135 | - $try = 'Patron\\' . $name; |
|
135 | + $try = 'Patron\\'.$name; |
|
136 | 136 | |
137 | 137 | if (function_exists($try)) |
138 | 138 | { |