Passed
Push — master ( c9d535...a1a723 )
by Thierry
10:07 queued 02:14
created
templates/cutealert/ready.js.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,10 +1,10 @@
 block discarded – undo
1
-<?php if(($this->defaultForMessage)): ?>
1
+<?php if (($this->defaultForMessage)): ?>
2 2
     jaxon.ajax.message.success = jaxon.dialogs.cutealert.success;
3 3
     jaxon.ajax.message.info = jaxon.dialogs.cutealert.info;
4 4
     jaxon.ajax.message.warning = jaxon.dialogs.cutealert.warning;
5 5
     jaxon.ajax.message.error = jaxon.dialogs.cutealert.error;
6 6
 <?php endif ?>
7
-<?php if(($this->defaultForQuestion)): ?>
7
+<?php if (($this->defaultForQuestion)): ?>
8 8
     jaxon.ajax.message.confirm = jaxon.dialogs.cutealert.confirm;
9 9
 <?php endif ?>
10 10
     jaxon.command.handler.register("cutealert.alert", function(args) {
Please login to merge, or discard this patch.
templates/xdialog/ready.js.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,10 +1,10 @@
 block discarded – undo
1
-<?php if(($this->defaultForMessage)): ?>
1
+<?php if (($this->defaultForMessage)): ?>
2 2
     jaxon.ajax.message.success = jaxon.dialogs.xdialog.success;
3 3
     jaxon.ajax.message.info = jaxon.dialogs.xdialog.info;
4 4
     jaxon.ajax.message.warning = jaxon.dialogs.xdialog.warning;
5 5
     jaxon.ajax.message.error = jaxon.dialogs.xdialog.error;
6 6
 <?php endif ?>
7
-<?php if(($this->defaultForQuestion)): ?>
7
+<?php if (($this->defaultForQuestion)): ?>
8 8
     jaxon.ajax.message.confirm = jaxon.dialogs.xdialog.confirm;
9 9
 <?php endif ?>
10 10
     jaxon.command.handler.register("xdialog.show", jaxon.dialogs.xdialog.show);
Please login to merge, or discard this patch.
src/CuteAlert/CuteAlertLibrary.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -86,11 +86,11 @@
 block discarded – undo
86 86
      */
87 87
     protected function alert(string $sContent, string $sTitle, string $sType): string
88 88
     {
89
-        if(!$sTitle)
89
+        if (!$sTitle)
90 90
         {
91 91
             $sTitle = '&nbsp;';
92 92
         }
93
-        if($this->returnCode())
93
+        if ($this->returnCode())
94 94
         {
95 95
             return "cuteAlert({message:" . $sContent . ", title:'" . $sTitle . "', type:'" . $sType . "'})";
96 96
         }
Please login to merge, or discard this patch.
src/start.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -24,13 +24,13 @@
 block discarded – undo
24 24
         Jaxon\Dialogs\CuteAlert\CuteAlertLibrary::class, // CuteAlert
25 25
     ];
26 26
     $jaxon = jaxon();
27
-    foreach($aLibraries as $sClass)
27
+    foreach ($aLibraries as $sClass)
28 28
     {
29 29
         try
30 30
         {
31 31
             $jaxon->dialog()->registerLibrary($sClass, $sClass::NAME);
32 32
         }
33
-        catch(SetupException $e){}
33
+        catch (SetupException $e) {}
34 34
     }
35 35
     // Register the template dir into the template renderer
36 36
     $jaxon->template()->addNamespace('jaxon::dialogs', dirname(__DIR__) . '/templates');
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,8 +29,7 @@
 block discarded – undo
29 29
         try
30 30
         {
31 31
             $jaxon->dialog()->registerLibrary($sClass, $sClass::NAME);
32
-        }
33
-        catch(SetupException $e){}
32
+        } catch(SetupException $e){}
34 33
     }
35 34
     // Register the template dir into the template renderer
36 35
     $jaxon->template()->addNamespace('jaxon::dialogs', dirname(__DIR__) . '/templates');
Please login to merge, or discard this patch.
src/Bootbox/BootboxLibrary.php 1 patch
Spacing   +2 added lines, -3 removed lines patch added patch discarded remove patch
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
      */
125 125
     protected function alert(string $sContent, string $sTitle, string $sType): string
126 126
     {
127
-        if($this->returnCode())
127
+        if ($this->returnCode())
128 128
         {
129 129
             return "jaxon.dialogs.bootbox.alert('" . $sType . "'," . $sContent . ",'" . $sTitle . "')";
130 130
         }
@@ -172,8 +172,7 @@  discard block
 block discarded – undo
172 172
         $sTitle = $this->helper()->getQuestionTitle();
173 173
 
174 174
         return empty($sNoScript) ?
175
-            "jaxon.dialogs.bootbox.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})" :
176
-            "jaxon.dialogs.bootbox.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript .
175
+            "jaxon.dialogs.bootbox.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})" : "jaxon.dialogs.bootbox.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript .
177 176
                 ";},function(){" . $sNoScript . ";})";
178 177
     }
179 178
 }
Please login to merge, or discard this patch.
src/XDialog/XDialogLibrary.php 2 patches
Spacing   +4 added lines, -5 removed lines patch added patch discarded remove patch
@@ -84,9 +84,9 @@  discard block
 block discarded – undo
84 84
         $aOptions['title'] = $sTitle;
85 85
         $aOptions['body'] = $sContent;
86 86
         $aOptions['buttons'] = [];
87
-        foreach($aButtons as $aButton)
87
+        foreach ($aButtons as $aButton)
88 88
         {
89
-            if($aButton['click'] === 'close')
89
+            if ($aButton['click'] === 'close')
90 90
             {
91 91
                 $aOptions['buttons']['cancel'] = $aButton['title'];
92 92
                 $aOptions['oncancel'] = 'jaxon.dialogs.xdialog.hide()';
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
      */
122 122
     protected function alert(string $sContent, string $sTitle, string $sType): string
123 123
     {
124
-        if($this->returnCode())
124
+        if ($this->returnCode())
125 125
         {
126 126
             return "jaxon.dialogs.xdialog.$sType(" . $sContent . "'" . $sTitle . "')";
127 127
         }
@@ -170,8 +170,7 @@  discard block
 block discarded – undo
170 170
         $sTitle = $this->helper()->getQuestionTitle();
171 171
 
172 172
         return empty($sNoScript) ?
173
-            "jaxon.dialogs.xdialog.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})" :
174
-            "jaxon.dialogs.xdialog.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript .
173
+            "jaxon.dialogs.xdialog.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})" : "jaxon.dialogs.xdialog.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript .
175 174
                 ";},function(){" . $sNoScript . ";})";
176 175
     }
177 176
 }
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -90,8 +90,7 @@
 block discarded – undo
90 90
             {
91 91
                 $aOptions['buttons']['cancel'] = $aButton['title'];
92 92
                 $aOptions['oncancel'] = 'jaxon.dialogs.xdialog.hide()';
93
-            }
94
-            else
93
+            } else
95 94
             {
96 95
                 $aOptions['buttons']['ok'] = $aButton['title'];
97 96
                 $aOptions['onok'] = $aButton['click'];
Please login to merge, or discard this patch.