Passed
Push — master ( 86de2c...0deb8f )
by Goffy
03:37
created
lib/Github/Http/Client/RetryableHttpClient.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@
 block discarded – undo
56 56
         $content = '';
57 57
         $firstChunk = null;
58 58
 
59
-        return new AsyncResponse($this->client, $method, $url, $options, function (ChunkInterface $chunk, AsyncContext $context) use ($method, $url, $options, &$retryCount, &$content, &$firstChunk) {
59
+        return new AsyncResponse($this->client, $method, $url, $options, function(ChunkInterface $chunk, AsyncContext $context) use ($method, $url, $options, &$retryCount, &$content, &$firstChunk) {
60 60
             $exception = null;
61 61
             try {
62 62
                 if ($chunk->isTimeout() || null !== $chunk->getInformationalStatus()) {
Please login to merge, or discard this patch.
directories.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -25,9 +25,9 @@  discard block
 block discarded – undo
25 25
 use XoopsModules\Wggithub\Constants;
26 26
 use XoopsModules\Wggithub\Common;
27 27
 
28
-require __DIR__ . '/header.php';
28
+require __DIR__.'/header.php';
29 29
 $GLOBALS['xoopsOption']['template_main'] = 'wggithub_directories.tpl';
30
-include_once \XOOPS_ROOT_PATH . '/header.php';
30
+include_once \XOOPS_ROOT_PATH.'/header.php';
31 31
 
32 32
 $op    = Request::getCmd('op', 'list');
33 33
 $start = Request::getInt('start', 0);
@@ -70,8 +70,8 @@  discard block
 block discarded – undo
70 70
 			unset($directories);
71 71
 			// Display Navigation
72 72
 			if ($directoriesCount > $limit) {
73
-				include_once \XOOPS_ROOT_PATH . '/class/pagenav.php';
74
-				$pagenav = new \XoopsPageNav($directoriesCount, $limit, $start, 'start', 'op=list&limit=' . $limit);
73
+				include_once \XOOPS_ROOT_PATH.'/class/pagenav.php';
74
+				$pagenav = new \XoopsPageNav($directoriesCount, $limit, $start, 'start', 'op=list&limit='.$limit);
75 75
 				$GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4));
76 76
 			}
77 77
 			$GLOBALS['xoopsTpl']->assign('type', $helper->getConfig('table_type'));
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
 $xoBreadcrumbs[] = ['title' => \_MA_WGGITHUB_DIRECTORIES];
86 86
 
87 87
 // Keywords
88
-wggithubMetaKeywords($helper->getConfig('keywords') . ', ' . \implode(',', $keywords));
88
+wggithubMetaKeywords($helper->getConfig('keywords').', '.\implode(',', $keywords));
89 89
 unset($keywords);
90 90
 
91 91
 // Description
@@ -93,4 +93,4 @@  discard block
 block discarded – undo
93 93
 $GLOBALS['xoopsTpl']->assign('xoops_mpageurl', WGGITHUB_URL.'/directories.php');
94 94
 $GLOBALS['xoopsTpl']->assign('wggithub_upload_url', WGGITHUB_UPLOAD_URL);
95 95
 
96
-require __DIR__ . '/footer.php';
96
+require __DIR__.'/footer.php';
Please login to merge, or discard this patch.
footer.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,4 +30,4 @@
 block discarded – undo
30 30
 $GLOBALS['xoopsTpl']->assign('admin', WGGITHUB_ADMIN);
31 31
 $GLOBALS['xoopsTpl']->assign('copyright', $copyright);
32 32
 // 
33
-include_once \XOOPS_ROOT_PATH . '/footer.php';
33
+include_once \XOOPS_ROOT_PATH.'/footer.php';
Please login to merge, or discard this patch.
repositories.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -25,9 +25,9 @@  discard block
 block discarded – undo
25 25
 use XoopsModules\Wggithub\Constants;
26 26
 use XoopsModules\Wggithub\Common;
27 27
 
28
-require __DIR__ . '/header.php';
28
+require __DIR__.'/header.php';
29 29
 $GLOBALS['xoopsOption']['template_main'] = 'wggithub_repositories.tpl';
30
-include_once XOOPS_ROOT_PATH . '/header.php';
30
+include_once XOOPS_ROOT_PATH.'/header.php';
31 31
 
32 32
 $op    = Request::getCmd('op', 'list');
33 33
 $start = Request::getInt('start', 0);
@@ -70,8 +70,8 @@  discard block
 block discarded – undo
70 70
 			unset($repositories);
71 71
 			// Display Navigation
72 72
 			if ($repositoriesCount > $limit) {
73
-				include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
74
-				$pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit=' . $limit);
73
+				include_once XOOPS_ROOT_PATH.'/class/pagenav.php';
74
+				$pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit='.$limit);
75 75
 				$GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4));
76 76
 			}
77 77
 			$GLOBALS['xoopsTpl']->assign('type', $helper->getConfig('table_type'));
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
 $xoBreadcrumbs[] = ['title' => _MA_WGGITHUB_REPOSITORIES];
86 86
 
87 87
 // Keywords
88
-wggithubMetaKeywords($helper->getConfig('keywords') . ', ' . \implode(',', $keywords));
88
+wggithubMetaKeywords($helper->getConfig('keywords').', '.\implode(',', $keywords));
89 89
 unset($keywords);
90 90
 
91 91
 // Description
@@ -93,4 +93,4 @@  discard block
 block discarded – undo
93 93
 $GLOBALS['xoopsTpl']->assign('xoops_mpageurl', WGGITHUB_URL.'/repositories.php');
94 94
 $GLOBALS['xoopsTpl']->assign('wggithub_upload_url', WGGITHUB_UPLOAD_URL);
95 95
 
96
-require __DIR__ . '/footer.php';
96
+require __DIR__.'/footer.php';
Please login to merge, or discard this patch.
class/Settings.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -127,7 +127,7 @@
 block discarded – undo
127 127
 		$ret['options']       = \strip_tags($this->getVar('set_options', 'e'));
128 128
 		$editorMaxchar = $helper->getConfig('editor_maxchar');
129 129
 		$ret['options_short'] = $utility::truncateHtml($ret['options'], $editorMaxchar);
130
-		$ret['primary']       = (int)$this->getVar('set_primary') > 0 ? _YES : _NO;
130
+		$ret['primary']       = (int) $this->getVar('set_primary') > 0 ? _YES : _NO;
131 131
 		$ret['date']          = \formatTimestamp($this->getVar('set_date'), 's');
132 132
 		$ret['submitter']     = \XoopsUser::getUnameFromId($this->getVar('set_submitter'));
133 133
 		return $ret;
Please login to merge, or discard this patch.
class/Common/ServerStats.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -36,19 +36,19 @@  discard block
 block discarded – undo
36 36
         //        $query = $GLOBALS['xoopsDB']->query($sql);
37 37
         //        list($meta) = $GLOBALS['xoopsDB']->fetchRow($query);
38 38
         $html .= '<fieldset>';
39
-        $html .= "<legend style='font-weight: bold; color: #900;'>" . \constant('CO_' . $moduleDirNameUpper . '_IMAGEINFO') . '</legend>';
39
+        $html .= "<legend style='font-weight: bold; color: #900;'>".\constant('CO_'.$moduleDirNameUpper.'_IMAGEINFO').'</legend>';
40 40
         $html .= "<div style='padding: 8px;'>";
41 41
         //        $html .= '<div>' . \constant('CO_' . $moduleDirNameUpper . '_METAVERSION') . $meta . "</div>";
42 42
         //        $html .= "<br>";
43 43
         //        $html .= "<br>";
44
-        $html .= '<div>' . \constant('CO_' . $moduleDirNameUpper . '_SPHPINI') . '</div>';
44
+        $html .= '<div>'.\constant('CO_'.$moduleDirNameUpper.'_SPHPINI').'</div>';
45 45
         $html .= '<ul>';
46 46
 
47
-        $gdlib = \function_exists('gd_info') ? '<span style="color: #008000;">' . \constant('CO_' . $moduleDirNameUpper . '_GDON') . '</span>' : '<span style="color: #ff0000;">' . \constant('CO_' . $moduleDirNameUpper . '_GDOFF') . '</span>';
48
-        $html  .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_GDLIBSTATUS') . $gdlib;
47
+        $gdlib = \function_exists('gd_info') ? '<span style="color: #008000;">'.\constant('CO_'.$moduleDirNameUpper.'_GDON').'</span>' : '<span style="color: #ff0000;">'.\constant('CO_'.$moduleDirNameUpper.'_GDOFF').'</span>';
48
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_GDLIBSTATUS').$gdlib;
49 49
         if (\function_exists('gd_info')) {
50 50
             if (true === ($gdlib = gd_info())) {
51
-                $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_GDLIBVERSION') . '<b>' . $gdlib['GD Version'] . '</b>';
51
+                $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_GDLIBVERSION').'<b>'.$gdlib['GD Version'].'</b>';
52 52
             }
53 53
         }
54 54
 
@@ -58,18 +58,18 @@  discard block
 block discarded – undo
58 58
         //    $registerglobals = (!\ini_get('register_globals')) ? "<span style=\"color: #008000;\">" . \constant('CO_' . $moduleDirNameUpper . '_OFF') . '</span>' : "<span style=\"color: #ff0000;\">" . \constant('CO_' . $moduleDirNameUpper . '_ON') . '</span>';
59 59
         //    $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_REGISTERGLOBALS . $registerglobals;
60 60
 
61
-        $downloads = \ini_get('file_uploads') ? '<span style="color: #008000;">' . \constant('CO_' . $moduleDirNameUpper . '_ON') . '</span>' : '<span style="color: #ff0000;">' . \constant('CO_' . $moduleDirNameUpper . '_OFF') . '</span>';
62
-        $html      .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_SERVERUPLOADSTATUS') . $downloads;
61
+        $downloads = \ini_get('file_uploads') ? '<span style="color: #008000;">'.\constant('CO_'.$moduleDirNameUpper.'_ON').'</span>' : '<span style="color: #ff0000;">'.\constant('CO_'.$moduleDirNameUpper.'_OFF').'</span>';
62
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_SERVERUPLOADSTATUS').$downloads;
63 63
 
64
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_MAXUPLOADSIZE') . ' <b><span style="color: #0000ff;">' . \ini_get('upload_max_filesize') . '</span></b>';
65
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_MAXPOSTSIZE') . ' <b><span style="color: #0000ff;">' . \ini_get('post_max_size') . '</span></b>';
66
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_MEMORYLIMIT') . ' <b><span style="color: #0000ff;">' . \ini_get('memory_limit') . '</span></b>';
64
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_MAXUPLOADSIZE').' <b><span style="color: #0000ff;">'.\ini_get('upload_max_filesize').'</span></b>';
65
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_MAXPOSTSIZE').' <b><span style="color: #0000ff;">'.\ini_get('post_max_size').'</span></b>';
66
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_MEMORYLIMIT').' <b><span style="color: #0000ff;">'.\ini_get('memory_limit').'</span></b>';
67 67
         $html .= '</ul>';
68 68
         $html .= '<ul>';
69
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_SERVERPATH') . ' <b>' . XOOPS_ROOT_PATH . '</b>';
69
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_SERVERPATH').' <b>'.XOOPS_ROOT_PATH.'</b>';
70 70
         $html .= '</ul>';
71 71
         $html .= '<br>';
72
-        $html .= \constant('CO_' . $moduleDirNameUpper . '_UPLOADPATHDSC') . '';
72
+        $html .= \constant('CO_'.$moduleDirNameUpper.'_UPLOADPATHDSC').'';
73 73
         $html .= '</div>';
74 74
         $html .= '</fieldset><br>';
75 75
 
Please login to merge, or discard this patch.
class/Common/Breadcrumb.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
         require $GLOBALS['xoops']->path('class/template.php');
74 74
         $breadcrumbTpl = new \XoopsTpl();
75 75
         $breadcrumbTpl->assign('breadcrumb', $this->bread);
76
-        $html = $breadcrumbTpl->fetch('db:' . $this->dirname . '_common_breadcrumb.tpl');
76
+        $html = $breadcrumbTpl->fetch('db:'.$this->dirname.'_common_breadcrumb.tpl');
77 77
         unset($breadcrumbTpl);
78 78
 
79 79
         return $html;
Please login to merge, or discard this patch.
class/Common/Resizer.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -146,14 +146,14 @@  discard block
 block discarded – undo
146 146
         $max_height_resize = $this->maxHeight;
147 147
         if ($original_w > $original_h) {
148 148
             $max_height_ratio = $this->maxHeight / $original_h;
149
-            $max_width_resize = (int)\round($original_w * $max_height_ratio);
149
+            $max_width_resize = (int) \round($original_w * $max_height_ratio);
150 150
         } else {
151 151
             $max_width_ratio   = $this->maxWidth / $original_w;
152
-            $max_height_resize = (int)\round($original_h * $max_width_ratio);
152
+            $max_height_resize = (int) \round($original_h * $max_width_ratio);
153 153
         }
154 154
         if ($max_width_resize < $this->maxWidth) {
155 155
             $max_height_ratio  = $this->maxWidth / $max_width_resize;
156
-            $max_height_resize = (int)\round($this->maxHeight * $max_height_ratio);
156
+            $max_height_resize = (int) \round($this->maxHeight * $max_height_ratio);
157 157
             $max_width_resize  = $this->maxWidth;
158 158
         }
159 159
 
@@ -168,9 +168,9 @@  discard block
 block discarded – undo
168 168
         $max_width_offset  = 0;
169 169
         $max_height_offset = 0;
170 170
         if ($this->maxWidth < $max_width_resize) {
171
-            $max_width_offset = (int)\round(($max_width_resize - $this->maxWidth) / 2);
171
+            $max_width_offset = (int) \round(($max_width_resize - $this->maxWidth) / 2);
172 172
         } else {
173
-            $max_height_offset = (int)\round(($max_height_resize - $this->maxHeight) / 2);
173
+            $max_height_offset = (int) \round(($max_height_resize - $this->maxHeight) / 2);
174 174
         }
175 175
 
176 176
         if (!imagecopy($final, $thumb, 0, 0, $max_width_offset, $max_height_offset, $max_width_resize, $max_height_resize)) {
@@ -189,10 +189,10 @@  discard block
 block discarded – undo
189 189
         $dest = \imagecreatefromjpeg($this->endFile);
190 190
         $src  = \imagecreatefromjpeg($this->sourceFile);
191 191
         if (4 == $this->mergeType) {
192
-            $imgWidth  = (int)\round($this->maxWidth / 2 - 1);
193
-            $imgHeight = (int)\round($this->maxHeight / 2 - 1);
194
-            $posCol2   = (int)\round($this->maxWidth / 2 + 1);
195
-            $posRow2   = (int)\round($this->maxHeight / 2 + 1);
192
+            $imgWidth  = (int) \round($this->maxWidth / 2 - 1);
193
+            $imgHeight = (int) \round($this->maxHeight / 2 - 1);
194
+            $posCol2   = (int) \round($this->maxWidth / 2 + 1);
195
+            $posRow2   = (int) \round($this->maxHeight / 2 + 1);
196 196
             switch ($this->mergePos) {
197 197
                 case 1:
198 198
                     imagecopy($dest, $src, 0, 0, 0, 0, $imgWidth, $imgHeight); //top left
@@ -209,11 +209,11 @@  discard block
 block discarded – undo
209 209
             }
210 210
         }
211 211
         if (6 == $this->mergeType) {
212
-            $imgWidth  = (int)\round($this->maxWidth / 3 - 1);
213
-            $imgHeight = (int)\round($this->maxHeight / 2 - 1);
214
-            $posCol2   = (int)\round($this->maxWidth / 3 + 1);
215
-            $posCol3   = $posCol2 + (int)\round($this->maxWidth / 3 + 1);
216
-            $posRow2   = (int)\round($this->maxHeight / 2 + 1);
212
+            $imgWidth  = (int) \round($this->maxWidth / 3 - 1);
213
+            $imgHeight = (int) \round($this->maxHeight / 2 - 1);
214
+            $posCol2   = (int) \round($this->maxWidth / 3 + 1);
215
+            $posCol3   = $posCol2 + (int) \round($this->maxWidth / 3 + 1);
216
+            $posRow2   = (int) \round($this->maxHeight / 2 + 1);
217 217
 
218 218
             switch ($this->mergePos) {
219 219
                 case 1:
Please login to merge, or discard this patch.
class/Common/Migrate.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
                 $this->synchronizeTable($tableName);
89 89
                 $updateTable = $GLOBALS['xoopsDB']->prefix($tableName);
90 90
                 $joinTable   = $GLOBALS['xoopsDB']->prefix($srcTableName);
91
-                $sql         = "UPDATE `$updateTable` t1 INNER JOIN `$joinTable` t2 ON t1.post_id = t2.post_id \n" . "SET t1.dohtml = t2.dohtml,  t1.dosmiley = t2.dosmiley, t1.doxcode = t2.doxcode\n" . '  , t1.doimage = t2.doimage, t1.dobr = t2.dobr';
91
+                $sql         = "UPDATE `$updateTable` t1 INNER JOIN `$joinTable` t2 ON t1.post_id = t2.post_id \n"."SET t1.dohtml = t2.dohtml,  t1.dosmiley = t2.dosmiley, t1.doxcode = t2.doxcode\n".'  , t1.doimage = t2.doimage, t1.dobr = t2.dobr';
92 92
                 $this->tableHandler->addToQueue($sql);
93 93
             }
94 94
         }
Please login to merge, or discard this patch.