Passed
Push — master ( 9b3a22...f80704 )
by Thierry
07:39 queued 05:30
created
templates/notify/ready.js.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php if(($this->defaultForMessage)): ?>
1
+<?php if (($this->defaultForMessage)): ?>
2 2
     jaxon.ajax.message.success = jaxon.dialogs.notify.success;
3 3
     jaxon.ajax.message.info = jaxon.dialogs.notify.info;
4 4
     jaxon.ajax.message.warning = jaxon.dialogs.notify.warning;
Please login to merge, or discard this patch.
templates/jalert/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.jalert.success;
3 3
     jaxon.ajax.message.info = jaxon.dialogs.jalert.info;
4 4
     jaxon.ajax.message.warning = jaxon.dialogs.jalert.warning;
5 5
     jaxon.ajax.message.error = jaxon.dialogs.jalert.error;
6 6
 <?php endif ?>
7
-<?php if(($this->defaultForQuestion)): ?>
7
+<?php if (($this->defaultForQuestion)): ?>
8 8
     jaxon.ajax.message.confirm = jaxon.dialogs.jalert.confirm;
9 9
 <?php endif ?>
10 10
     jaxon.command.handler.register("jalert.alert", function(args) {
Please login to merge, or discard this patch.
src/JAlert/JAlertLibrary.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -93,11 +93,11 @@  discard block
 block discarded – undo
93 93
      */
94 94
     protected function alert(string $sContent, string $sTitle, string $sTheme): string
95 95
     {
96
-        if(!$sTitle)
96
+        if (!$sTitle)
97 97
         {
98 98
             $sTitle = '&nbsp;';
99 99
         }
100
-        if($this->returnCode())
100
+        if ($this->returnCode())
101 101
         {
102 102
             return "$.jAlert({content:" . $sContent . ", title:'" . $sTitle . "', theme:'" . $sTheme . "'})";
103 103
         }
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
     public function confirm(string $sQuestion, string $sYesScript, string $sNoScript): string
144 144
     {
145 145
         $sTitle = $this->helper()->getQuestionTitle();
146
-        if(!$sNoScript)
146
+        if (!$sNoScript)
147 147
         {
148 148
             return "jaxon.dialogs.jalert.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})";
149 149
         }
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -125,8 +125,7 @@
 block discarded – undo
125 125
         if(!$sNoScript)
126 126
         {
127 127
             return "jaxon.dialogs.jalert.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})";
128
-        }
129
-        else
128
+        } else
130 129
         {
131 130
             return "jaxon.dialogs.jalert.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";},function(){" . $sNoScript . ";})";
132 131
         }
Please login to merge, or discard this patch.
src/Toastr/ToastrLibrary.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -91,7 +91,7 @@
 block discarded – undo
91 91
      */
92 92
     protected function alert(string $sMessage, string $sTitle, string $sType): string
93 93
     {
94
-        if($this->returnCode())
94
+        if ($this->returnCode())
95 95
         {
96 96
             return empty($sTitle) ? "toastr.$sType($sMessage)" : "toastr.$sType($sMessage, '$sTitle')";
97 97
         }
Please login to merge, or discard this patch.
src/JQueryConfirm/JQueryConfirmLibrary.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -97,13 +97,13 @@  discard block
 block discarded – undo
97 97
         $aOptions['title'] = $sTitle;
98 98
         $aOptions['content'] = $sMessage;
99 99
         $aOptions['buttons'] = [];
100
-        if(!array_key_exists('boxWidth', $aOptions))
100
+        if (!array_key_exists('boxWidth', $aOptions))
101 101
         {
102 102
             $aOptions['useBootstrap'] = false;
103 103
             $aOptions['boxWidth'] = '600';
104 104
         }
105 105
         $ind = 0;
106
-        foreach($aButtons as $button)
106
+        foreach ($aButtons as $button)
107 107
         {
108 108
             $_button = [
109 109
                 'text' => $button['title'],
@@ -111,9 +111,9 @@  discard block
 block discarded – undo
111 111
                 'action' => $button['click'],
112 112
             ];
113 113
             // Optional attributes
114
-            foreach($button as $attr => $value)
114
+            foreach ($button as $attr => $value)
115 115
             {
116
-                if(!in_array($attr, ['title', 'class', 'click']))
116
+                if (!in_array($attr, ['title', 'class', 'click']))
117 117
                 {
118 118
                     $_button[$attr] = $value;
119 119
                 }
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
      */
146 146
     protected function alert(string $sMessage, string $sTitle, string $sType, string $sIcon): string
147 147
     {
148
-        if($this->returnCode())
148
+        if ($this->returnCode())
149 149
         {
150 150
             return "$.alert({content:" . $sMessage . ", title:'" . $sTitle .
151 151
                 "', type:'" . $sType . "', icon:'" . $sIcon . "'})";
@@ -193,7 +193,7 @@  discard block
 block discarded – undo
193 193
     public function confirm(string $sQuestion, string $sYesScript, string $sNoScript): string
194 194
     {
195 195
         $sTitle = $this->helper()->getQuestionTitle();
196
-        if(!$sNoScript)
196
+        if (!$sNoScript)
197 197
         {
198 198
             return "jaxon.dialogs.jconfirm.confirm(" . $sQuestion . ",'" .
199 199
                 $sTitle . "',function(){" . $sYesScript . ";})";
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
@@ -36,13 +36,13 @@
 block discarded – undo
36 36
         'jconfirm'      => Jaxon\Dialogs\JQueryConfirm\JQueryConfirmLibrary::class,
37 37
     ];
38 38
     $jaxon = jaxon();
39
-    foreach($aLibraries as $sName => $sClass)
39
+    foreach ($aLibraries as $sName => $sClass)
40 40
     {
41 41
         try
42 42
         {
43 43
             $jaxon->dialog()->registerLibrary($sClass, $sName);
44 44
         }
45
-        catch(SetupException $e){}
45
+        catch (SetupException $e) {}
46 46
     }
47 47
     // Register the template dir into the template renderer
48 48
     $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
@@ -41,8 +41,7 @@
 block discarded – undo
41 41
         try
42 42
         {
43 43
             $jaxon->dialog()->registerLibrary($sClass, $sName);
44
-        }
45
-        catch(SetupException $e){}
44
+        } catch(SetupException $e){}
46 45
     }
47 46
     // Register the template dir into the template renderer
48 47
     $jaxon->template()->addNamespace('jaxon::dialogs', dirname(__DIR__) . '/templates');
Please login to merge, or discard this patch.
src/SweetAlert/SweetAlertLibrary.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -95,12 +95,12 @@  discard block
 block discarded – undo
95 95
      */
96 96
     protected function alert(string $sMessage, string $sTitle, string $sType): string
97 97
     {
98
-        if($this->returnCode())
98
+        if ($this->returnCode())
99 99
         {
100 100
             return "swal({text:" . $sMessage . ", title:'" . $sTitle . "', type:'" . $sType . "'})";
101 101
         }
102 102
         $aOptions = ['text' => $sMessage, 'title' => '', 'type' => $sType];
103
-        if(($sTitle))
103
+        if (($sTitle))
104 104
         {
105 105
             $aOptions['title'] = $sTitle;
106 106
         }
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
     public function confirm(string $sQuestion, string $sYesScript, string $sNoScript): string
148 148
     {
149 149
         $sTitle = $this->helper()->getQuestionTitle();
150
-        if(!$sNoScript)
150
+        if (!$sNoScript)
151 151
         {
152 152
             return "jaxon.dialogs.swal.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})";
153 153
         }
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -122,8 +122,7 @@
 block discarded – undo
122 122
         if(!$sNoScript)
123 123
         {
124 124
             return "jaxon.dialogs.swal.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";})";
125
-        }
126
-        else
125
+        } else
127 126
         {
128 127
             return "jaxon.dialogs.swal.confirm(" . $sQuestion . ",'" . $sTitle . "',function(){" . $sYesScript . ";},function(){" . $sNoScript . ";})";
129 128
         }
Please login to merge, or discard this patch.
src/Noty/NotyLibrary.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
      */
64 64
     public function getScript(): string
65 65
     {
66
-         return $this->helper()->render('noty/alert.js');
66
+            return $this->helper()->render('noty/alert.js');
67 67
     }
68 68
 
69 69
     /**
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
      */
72 72
     public function getReadyScript(): string
73 73
     {
74
-         return $this->helper()->render('noty/ready.js.php');
74
+            return $this->helper()->render('noty/ready.js.php');
75 75
     }
76 76
 
77 77
     /**
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
      */
86 86
     protected function alert(string $sMessage, string $sTitle, string $sType): string
87 87
     {
88
-        if($this->returnCode())
88
+        if ($this->returnCode())
89 89
         {
90 90
             return "noty({text:" . $sMessage . ", type:'" . $sType . "', layout: 'topCenter'})";
91 91
         }
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
     public function confirm(string $sQuestion, string $sYesScript, string $sNoScript): string
134 134
     {
135 135
         // $sTitle = $this->helper()->getQuestionTitle();
136
-        if(!$sNoScript)
136
+        if (!$sNoScript)
137 137
         {
138 138
             return "jaxon.dialogs.noty.confirm(" . $sQuestion . ",'',function(){" . $sYesScript . ";})";
139 139
         }
Please login to merge, or discard this patch.
src/Notify/NotifyLibrary.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@
 block discarded – undo
81 81
      */
82 82
     protected function alert(string $sMessage, string $sTitle, string $sClass): string
83 83
     {
84
-        if($this->returnCode())
84
+        if ($this->returnCode())
85 85
         {
86 86
             return "$.notify(" . $sMessage . ", {className:'" . $sClass . "', position:'top center'})";
87 87
         }
Please login to merge, or discard this patch.