Passed
Push — develop ( e642d1...f1ab93 )
by Benjamin
09:42 queued 04:58
created
src/gateways/Vimeo.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -504,7 +504,7 @@
 block discarded – undo
504 504
     {
505 505
         $privacyOptions = ['nobody', 'contacts', 'password', 'users', 'disable'];
506 506
 
507
-        if(in_array($data['privacy']['view'], $privacyOptions, true)) {
507
+        if (in_array($data['privacy']['view'], $privacyOptions, true)) {
508 508
             $video->private = true;
509 509
         }
510 510
 
Please login to merge, or discard this patch.
src/helpers/VideosHelper.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
      */
29 29
     public static function getDuration($seconds): string
30 30
     {
31
-        $hours = (int)((int)$seconds / 3600);
31
+        $hours = (int) ((int) $seconds / 3600);
32 32
         $minutes = (($seconds / 60) % 60);
33 33
         $seconds %= 60;
34 34
 
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
      */
55 55
     public static function getDuration8601($seconds): string
56 56
     {
57
-        $hours = (int)((int)$seconds / 3600);
57
+        $hours = (int) ((int) $seconds / 3600);
58 58
         $minutes = (($seconds / 60) % 60);
59 59
         $seconds %= 60;
60 60
 
Please login to merge, or discard this patch.
src/base/Gateway.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -232,7 +232,7 @@  discard block
 block discarded – undo
232 232
     public function getEmbedHtml($videoId, array $options = []): string
233 233
     {
234 234
         $embedAttributes = [
235
-            'title' => 'External video from ' . $this->getHandle(),
235
+            'title' => 'External video from '.$this->getHandle(),
236 236
             'frameborder' => '0',
237 237
             'allowfullscreen' => 'true',
238 238
             'allowscriptaccess' => 'true',
@@ -248,7 +248,7 @@  discard block
 block discarded – undo
248 248
 
249 249
         $title = $options['title'] ?? false;
250 250
 
251
-        if($title) {
251
+        if ($title) {
252 252
             $this->parseEmbedAttribute($embedAttributes, $options, 'title', 'title');
253 253
         }
254 254
 
@@ -421,11 +421,11 @@  discard block
 block discarded – undo
421 421
 
422 422
         try {
423 423
             $response = $client->request('GET', $uri, $options);
424
-            $body = (string)$response->getBody();
424
+            $body = (string) $response->getBody();
425 425
             $data = Json::decode($body);
426 426
         } catch (BadResponseException $badResponseException) {
427 427
             $response = $badResponseException->getResponse();
428
-            $body = (string)$response->getBody();
428
+            $body = (string) $response->getBody();
429 429
 
430 430
             try {
431 431
                 $data = Json::decode($body);
Please login to merge, or discard this patch.
src/controllers/SettingsController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -133,7 +133,7 @@
 block discarded – undo
133 133
         ];
134 134
 
135 135
         $key = 'plugins.videos.settings.oauthProviderOptions';
136
-        $configPath = $key . '.' . $gateway->getHandle();
136
+        $configPath = $key.'.'.$gateway->getHandle();
137 137
 
138 138
         Craft::$app->getProjectConfig()->set($configPath, $configData, "Save the “{$gateway->getHandle()}” integration");
139 139
 
Please login to merge, or discard this patch.
src/migrations/m200925_135118_refactor_oauth_provider_options.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
             // Get OAuth provider options
26 26
             $oauthProviderOptions = $projectConfig->get('plugins.videos.settings.oauthProviderOptions', true);
27 27
 
28
-            if(!is_array($oauthProviderOptions)) {
28
+            if (!is_array($oauthProviderOptions)) {
29 29
                 return true;
30 30
             }
31 31
 
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
             $projectConfig->set('plugins.videos.settings.oauthProviderOptions', [], "Reset the oauth provider options");
36 36
 
37 37
             // Rebuild OAuth provider options
38
-            foreach($oauthProviderOptions as $providerHandle => $provider) {
38
+            foreach ($oauthProviderOptions as $providerHandle => $provider) {
39 39
                 $projectConfig->set('plugins.videos.settings.oauthProviderOptions.'.$providerHandle, $provider, "Save the “{$providerHandle}” provider");
40 40
             }
41 41
         }
Please login to merge, or discard this patch.
src/gateways/YouTube.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -100,7 +100,7 @@
 block discarded – undo
100 100
     {
101 101
         $options = parent::getOauthProviderOptions($parse);
102 102
 
103
-        if(!isset($options['useOidcMode'])) {
103
+        if (!isset($options['useOidcMode'])) {
104 104
             $options['useOidcMode'] = true;
105 105
         }
106 106
 
Please login to merge, or discard this patch.