File tree Expand file tree Collapse file tree 4 files changed +17
-7
lines changed Expand file tree Collapse file tree 4 files changed +17
-7
lines changed Original file line number Diff line number Diff line change 7
7
namespace Magento \Marketplace \Block ;
8
8
9
9
/**
10
+ * Partners section block.
11
+ *
10
12
* @api
11
13
* @since 100.0.2
12
14
*/
@@ -39,7 +41,7 @@ public function __construct(
39
41
/**
40
42
* Gets partners
41
43
*
42
- * @return bool|string
44
+ * @return array
43
45
*/
44
46
public function getPartners ()
45
47
{
Original file line number Diff line number Diff line change 12
12
use Zend \Uri \Uri ;
13
13
use Zend \Uri \UriFactory ;
14
14
15
+ /**
16
+ * Cache server model.
17
+ */
15
18
class Server
16
19
{
17
20
/**
@@ -62,8 +65,7 @@ public function getUris()
62
65
foreach ($ configuredHosts as $ host ) {
63
66
$ servers [] = UriFactory::factory ('' )
64
67
->setHost ($ host ['host ' ])
65
- ->setPort (isset ($ host ['port ' ]) ? $ host ['port ' ] : self ::DEFAULT_PORT )
66
- ;
68
+ ->setPort (isset ($ host ['port ' ]) ? $ host ['port ' ] : self ::DEFAULT_PORT );
67
69
}
68
70
} elseif ($ this ->request ->getHttpHost ()) {
69
71
$ servers [] = UriFactory::factory ('' )->setHost ($ this ->request ->getHttpHost ())->setPort (self ::DEFAULT_PORT );
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ public function beforeSave()
28
28
throw new LocalizedException (
29
29
new Phrase (
30
30
'Access List value "%1" is not valid. '
31
- .'Please use only IP addresses and host names. ' ,
31
+ . 'Please use only IP addresses and host names. ' ,
32
32
[$ value ]
33
33
)
34
34
);
Original file line number Diff line number Diff line change 9
9
use Magento \PageCache \Model \VclGeneratorInterface ;
10
10
use Magento \PageCache \Model \VclTemplateLocatorInterface ;
11
11
12
+ /**
13
+ * Varnish vcl generator model.
14
+ */
12
15
class VclGenerator implements VclGeneratorInterface
13
16
{
14
17
/**
@@ -119,7 +122,7 @@ private function getReplacements()
119
122
private function getRegexForDesignExceptions ()
120
123
{
121
124
$ result = '' ;
122
- $ tpl = "%s (req.http.user-agent ~ \"%s \") { \n" . " hash_data( \"%s \"); \n" . " } " ;
125
+ $ tpl = "%s (req.http.user-agent ~ \"%s \") { \n" . " hash_data( \"%s \"); \n" . " } " ;
123
126
124
127
$ expressions = $ this ->getDesignExceptions ();
125
128
@@ -143,7 +146,8 @@ private function getRegexForDesignExceptions()
143
146
144
147
/**
145
148
* Get IPs access list that can purge Varnish configuration for config file generation
146
- * and transform it to appropriate view
149
+ *
150
+ * Tansform it to appropriate view
147
151
*
148
152
* acl purge{
149
153
* "127.0.0.1";
@@ -157,7 +161,7 @@ private function getTransformedAccessList()
157
161
$ result = array_reduce (
158
162
$ this ->getAccessList (),
159
163
function ($ ips , $ ip ) use ($ tpl ) {
160
- return $ ips. sprintf ($ tpl , trim ($ ip )) . "\n" ;
164
+ return $ ips . sprintf ($ tpl , trim ($ ip )) . "\n" ;
161
165
},
162
166
''
163
167
);
@@ -216,6 +220,8 @@ private function getSslOffloadedHeader()
216
220
}
217
221
218
222
/**
223
+ * Get design exceptions array.
224
+ *
219
225
* @return array
220
226
*/
221
227
private function getDesignExceptions ()
You can’t perform that action at this time.
0 commit comments