@@ -25,7 +25,7 @@ discard block |
||
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 | // It recovered the value of argument op in URL$ |
30 | 30 | $op = Request::getCmd('op', 'list'); |
31 | 31 | $rmId = Request::getInt('rm_id'); |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | $in[] = $i; |
65 | 65 | } |
66 | 66 | } |
67 | - $crReadmes->add(new Criteria('rm_repoid', '(' . implode(',', $in) . ')', 'IN')); |
|
67 | + $crReadmes->add(new Criteria('rm_repoid', '('.implode(',', $in).')', 'IN')); |
|
68 | 68 | } |
69 | 69 | $crReadmes->setStart($start); |
70 | 70 | $crReadmes->setLimit($limit); |
@@ -82,8 +82,8 @@ discard block |
||
82 | 82 | } |
83 | 83 | // Display Navigation |
84 | 84 | if ($readmesCount > $limit) { |
85 | - include_once XOOPS_ROOT_PATH . '/class/pagenav.php'; |
|
86 | - $pagenav = new \XoopsPageNav($readmesCount, $limit, $start, 'start', 'op=list&limit=' . $limit); |
|
85 | + include_once XOOPS_ROOT_PATH.'/class/pagenav.php'; |
|
86 | + $pagenav = new \XoopsPageNav($readmesCount, $limit, $start, 'start', 'op=list&limit='.$limit); |
|
87 | 87 | $GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4)); |
88 | 88 | } |
89 | 89 | $form = $readmesHandler->getFormFilterReadmes(false, $start, $limit); |
@@ -125,7 +125,7 @@ discard block |
||
125 | 125 | $readmesObj->setVar('rm_submitter', Request::getInt('rm_submitter', 0)); |
126 | 126 | // Insert Data |
127 | 127 | if ($readmesHandler->insert($readmesObj)) { |
128 | - \redirect_header('readmes.php?op=list&start=' . $start . '&limit=' . $limit, 2, _AM_WGGITHUB_FORM_OK); |
|
128 | + \redirect_header('readmes.php?op=list&start='.$start.'&limit='.$limit, 2, _AM_WGGITHUB_FORM_OK); |
|
129 | 129 | } |
130 | 130 | // Get Form |
131 | 131 | $GLOBALS['xoopsTpl']->assign('error', $readmesObj->getHtmlErrors()); |
@@ -167,4 +167,4 @@ discard block |
||
167 | 167 | } |
168 | 168 | break; |
169 | 169 | } |
170 | -require __DIR__ . '/footer.php'; |
|
170 | +require __DIR__.'/footer.php'; |
@@ -25,7 +25,7 @@ discard block |
||
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 | // It recovered the value of argument op in URL$ |
30 | 30 | $op = Request::getCmd('op', 'list'); |
31 | 31 | $relId = Request::getInt('rel_id'); |
@@ -71,8 +71,8 @@ discard block |
||
71 | 71 | } |
72 | 72 | // Display Navigation |
73 | 73 | if ($releasesCount > $limit) { |
74 | - include_once XOOPS_ROOT_PATH . '/class/pagenav.php'; |
|
75 | - $pagenav = new \XoopsPageNav($releasesCount, $limit, $start, 'start', 'op=list&limit=' . $limit); |
|
74 | + include_once XOOPS_ROOT_PATH.'/class/pagenav.php'; |
|
75 | + $pagenav = new \XoopsPageNav($releasesCount, $limit, $start, 'start', 'op=list&limit='.$limit); |
|
76 | 76 | $GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4)); |
77 | 77 | } |
78 | 78 | $form = $releasesHandler->getFormFilterReleases(false, $start, $limit); |
@@ -114,7 +114,7 @@ discard block |
||
114 | 114 | $releasesObj->setVar('rel_submitter', Request::getInt('rel_submitter', 0)); |
115 | 115 | // Insert Data |
116 | 116 | if ($releasesHandler->insert($releasesObj)) { |
117 | - \redirect_header('releases.php?op=list&start=' . $start . '&limit=' . $limit, 2, _AM_WGGITHUB_FORM_OK); |
|
117 | + \redirect_header('releases.php?op=list&start='.$start.'&limit='.$limit, 2, _AM_WGGITHUB_FORM_OK); |
|
118 | 118 | } |
119 | 119 | // Get Form |
120 | 120 | $GLOBALS['xoopsTpl']->assign('error', $releasesObj->getHtmlErrors()); |
@@ -156,4 +156,4 @@ discard block |
||
156 | 156 | } |
157 | 157 | break; |
158 | 158 | } |
159 | -require __DIR__ . '/footer.php'; |
|
159 | +require __DIR__.'/footer.php'; |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | Github\GithubClient |
28 | 28 | }; |
29 | 29 | |
30 | -require __DIR__ . '/header.php'; |
|
30 | +require __DIR__.'/header.php'; |
|
31 | 31 | // It recovered the value of argument op in URL$ |
32 | 32 | $op = Request::getCmd('op', 'list'); |
33 | 33 | $dirId = Request::getInt('dir_id'); |
@@ -41,8 +41,8 @@ discard block |
||
41 | 41 | default: |
42 | 42 | // Define Stylesheet |
43 | 43 | $GLOBALS['xoTheme']->addStylesheet($style, null); |
44 | - $GLOBALS['xoTheme']->addScript(WGGITHUB_URL . '/assets/js/jquery-ui.js'); |
|
45 | - $GLOBALS['xoTheme']->addScript(WGGITHUB_URL . '/assets/js/sortable.js'); |
|
44 | + $GLOBALS['xoTheme']->addScript(WGGITHUB_URL.'/assets/js/jquery-ui.js'); |
|
45 | + $GLOBALS['xoTheme']->addScript(WGGITHUB_URL.'/assets/js/sortable.js'); |
|
46 | 46 | $templateMain = 'wggithub_admin_directories.tpl'; |
47 | 47 | $GLOBALS['xoopsTpl']->assign('navigation', $adminObject->displayNavigation('directories.php')); |
48 | 48 | $adminObject->addItemButton(_AM_WGGITHUB_ADD_DIRECTORY, 'directories.php?op=new', 'add'); |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | $GLOBALS['xoopsTpl']->assign('directories_count', $directoriesCount); |
53 | 53 | $GLOBALS['xoopsTpl']->assign('wggithub_url', WGGITHUB_URL); |
54 | 54 | $GLOBALS['xoopsTpl']->assign('wggithub_upload_url', WGGITHUB_UPLOAD_URL); |
55 | - $GLOBALS['xoopsTpl']->assign('wggithub_icons_url_16', WGGITHUB_ICONS_URL . '/16'); |
|
55 | + $GLOBALS['xoopsTpl']->assign('wggithub_icons_url_16', WGGITHUB_ICONS_URL.'/16'); |
|
56 | 56 | // Table view directories |
57 | 57 | if ($directoriesCount > 0) { |
58 | 58 | foreach (\array_keys($directoriesAll) as $i) { |
@@ -62,8 +62,8 @@ discard block |
||
62 | 62 | } |
63 | 63 | // Display Navigation |
64 | 64 | if ($directoriesCount > $limit) { |
65 | - include_once XOOPS_ROOT_PATH . '/class/pagenav.php'; |
|
66 | - $pagenav = new \XoopsPageNav($directoriesCount, $limit, $start, 'start', 'op=list&limit=' . $limit); |
|
65 | + include_once XOOPS_ROOT_PATH.'/class/pagenav.php'; |
|
66 | + $pagenav = new \XoopsPageNav($directoriesCount, $limit, $start, 'start', 'op=list&limit='.$limit); |
|
67 | 67 | $GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4)); |
68 | 68 | } |
69 | 69 | } else { |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | $directoriesObj->setVar('dir_submitter', Request::getInt('dir_submitter', 0)); |
104 | 104 | // Insert Data |
105 | 105 | if ($directoriesHandler->insert($directoriesObj)) { |
106 | - \redirect_header('directories.php?op=list&start=' . $start . '&limit=' . $limit, 2, _AM_WGGITHUB_FORM_OK); |
|
106 | + \redirect_header('directories.php?op=list&start='.$start.'&limit='.$limit, 2, _AM_WGGITHUB_FORM_OK); |
|
107 | 107 | } |
108 | 108 | // Get Form |
109 | 109 | $GLOBALS['xoopsTpl']->assign('error', $directoriesObj->getHtmlErrors()); |
@@ -142,7 +142,7 @@ discard block |
||
142 | 142 | $crReadmes = new \CriteriaCompo(); |
143 | 143 | $crReadmes->add(new \Criteria('rm_repoid', $repoId)); |
144 | 144 | if (!$readmesHandler->deleteAll($crReadmes)) { |
145 | - $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA . ' READMES'; |
|
145 | + $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA.' READMES'; |
|
146 | 146 | } |
147 | 147 | } |
148 | 148 | if ($repositoriesAll[$i]->getVar('repo_release') > 0 || $repositoriesAll[$i]->getVar('repo_prerelease') > 0) { |
@@ -150,17 +150,17 @@ discard block |
||
150 | 150 | $crReleases = new \CriteriaCompo(); |
151 | 151 | $crReleases->add(new \Criteria('rel_repoid', $repoId)); |
152 | 152 | if (!$releasesHandler->deleteAll($crReleases)) { |
153 | - $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA . ' RELEASES'; |
|
153 | + $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA.' RELEASES'; |
|
154 | 154 | } |
155 | 155 | } |
156 | 156 | } |
157 | 157 | if (!$repositoriesHandler->deleteAll($crRepositories)) { |
158 | - $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA . ' REPOSITORIES'; |
|
158 | + $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA.' REPOSITORIES'; |
|
159 | 159 | } |
160 | 160 | unset($crReadmes, $crReleases, $repositoriesAll); |
161 | 161 | //delete directory |
162 | 162 | if (!$directoriesHandler->delete($directoriesObj)) { |
163 | - $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA . ' DIRECTORIES - ' . $directoriesObj->getHtmlErrors(); |
|
163 | + $errors[] = \_AM_WGGITHUB_ERROR_DELETE_DATA.' DIRECTORIES - '.$directoriesObj->getHtmlErrors(); |
|
164 | 164 | } |
165 | 165 | if (0 == \count($errors)) { |
166 | 166 | \redirect_header('directories.php', 3, _AM_WGGITHUB_FORM_DELETE_OK); |
@@ -181,7 +181,7 @@ discard block |
||
181 | 181 | $dirName = $directoriesObj->getVar('dir_name'); |
182 | 182 | $githubClient = GithubClient::getInstance(); |
183 | 183 | $result = $githubClient->executeUpdate($dirName); |
184 | - $redir = 'directories.php?op=list&start=' . $start . '&limit=' . $limit; |
|
184 | + $redir = 'directories.php?op=list&start='.$start.'&limit='.$limit; |
|
185 | 185 | if ($result) { |
186 | 186 | \redirect_header($redir, 2, \_MA_WGGITHUB_READGH_SUCCESS); |
187 | 187 | } else { |
@@ -194,7 +194,7 @@ discard block |
||
194 | 194 | $directoriesObj->setVar(Request::getString('field'), Request::getInt('value', 0)); |
195 | 195 | // Insert Data |
196 | 196 | if ($directoriesHandler->insert($directoriesObj, true)) { |
197 | - \redirect_header('directories.php?op=list&start=' . $start . '&limit=' . $limit, 2, _AM_WGGITHUB_FORM_OK); |
|
197 | + \redirect_header('directories.php?op=list&start='.$start.'&limit='.$limit, 2, _AM_WGGITHUB_FORM_OK); |
|
198 | 198 | } |
199 | 199 | } |
200 | 200 | break; |
@@ -207,4 +207,4 @@ discard block |
||
207 | 207 | } |
208 | 208 | break; |
209 | 209 | } |
210 | -require __DIR__ . '/footer.php'; |
|
210 | +require __DIR__.'/footer.php'; |
@@ -25,7 +25,7 @@ discard block |
||
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 | // It recovered the value of argument op in URL$ |
30 | 30 | $op = Request::getCmd('op', 'list'); |
31 | 31 | $repoId = Request::getInt('repo_id'); |
@@ -72,8 +72,8 @@ discard block |
||
72 | 72 | } |
73 | 73 | // Display Navigation |
74 | 74 | if ($repositoriesCount > $limit) { |
75 | - include_once XOOPS_ROOT_PATH . '/class/pagenav.php'; |
|
76 | - $pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit=' . $limit); |
|
75 | + include_once XOOPS_ROOT_PATH.'/class/pagenav.php'; |
|
76 | + $pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit='.$limit); |
|
77 | 77 | $GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4)); |
78 | 78 | } |
79 | 79 | $form = $repositoriesHandler->getFormFilterRepos(false, $start, $limit); |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | $repositoriesObj->setVar('repo_submitter', Request::getInt('repo_submitter', 0)); |
121 | 121 | // Insert Data |
122 | 122 | if ($repositoriesHandler->insert($repositoriesObj)) { |
123 | - \redirect_header('repositories.php?op=list&start=' . $start . '&limit=' . $limit, 2, _AM_WGGITHUB_FORM_OK); |
|
123 | + \redirect_header('repositories.php?op=list&start='.$start.'&limit='.$limit, 2, _AM_WGGITHUB_FORM_OK); |
|
124 | 124 | } |
125 | 125 | // Get Form |
126 | 126 | $GLOBALS['xoopsTpl']->assign('error', $repositoriesObj->getHtmlErrors()); |
@@ -162,4 +162,4 @@ discard block |
||
162 | 162 | } |
163 | 163 | break; |
164 | 164 | } |
165 | -require __DIR__ . '/footer.php'; |
|
165 | +require __DIR__.'/footer.php'; |
@@ -140,7 +140,7 @@ |
||
140 | 140 | $submitter = isset($GLOBALS['xoopsUser']) && \is_object($GLOBALS['xoopsUser']) ? $GLOBALS['xoopsUser']->getVar('uid') : 0; |
141 | 141 | // add/update all items from table repositories |
142 | 142 | foreach ($repos as $key => $repo) { |
143 | - $fork = (bool)$repo['fork']; |
|
143 | + $fork = (bool) $repo['fork']; |
|
144 | 144 | if (Constants::DIRECTORY_CONTENT_ALL == $dirContent || false === $fork) { |
145 | 145 | $crRepositories = new \CriteriaCompo(); |
146 | 146 | $crRepositories->add(new \Criteria('repo_nodeid', $repo['node_id'])); |
@@ -170,7 +170,7 @@ discard block |
||
170 | 170 | $readmesObj->setVar('rm_content', $readme['content']); |
171 | 171 | $readmesObj->setVar('rm_encoding', $readme['encoding']); |
172 | 172 | $readmesObj->setVar('rm_downloadurl', $readme['download_url']); |
173 | - $readmesObj->setVar('rm_datecreated',time()); |
|
173 | + $readmesObj->setVar('rm_datecreated', time()); |
|
174 | 174 | $readmesObj->setVar('rm_submitter', $submitter); |
175 | 175 | // Insert Data |
176 | 176 | if (!$readmesHandler->insert($readmesObj)) { |
@@ -232,7 +232,7 @@ discard block |
||
232 | 232 | $readmesObj->setVar('rm_downloadurl', $readme['download_url']); |
233 | 233 | $baseurl = \substr($readme['html_url'], 0, \strrpos($readme['html_url'], '/') + 1); |
234 | 234 | $readmesObj->setVar('rm_baseurl', $baseurl); |
235 | - $readmesObj->setVar('rm_datecreated',time()); |
|
235 | + $readmesObj->setVar('rm_datecreated', time()); |
|
236 | 236 | $readmesObj->setVar('rm_submitter', $submitter); |
237 | 237 | // Insert Data |
238 | 238 | if (!$readmesHandler->insert($readmesObj)) { |
@@ -266,10 +266,10 @@ discard block |
||
266 | 266 | public function updateRepoReadme() |
267 | 267 | { |
268 | 268 | // update repo_readme |
269 | - $sql = 'UPDATE ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . ' INNER JOIN ' . $GLOBALS['xoopsDB']->prefix('wggithub_readmes'); |
|
270 | - $sql .= ' ON ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . '.repo_id = ' . $GLOBALS['xoopsDB']->prefix('wggithub_readmes') . '.rm_repoid '; |
|
271 | - $sql .= 'SET ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . '.repo_readme = 1 '; |
|
272 | - $sql .= 'WHERE (((' . $GLOBALS['xoopsDB']->prefix('wggithub_readmes') . '.rm_id)>0));'; |
|
269 | + $sql = 'UPDATE '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').' INNER JOIN '.$GLOBALS['xoopsDB']->prefix('wggithub_readmes'); |
|
270 | + $sql .= ' ON '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').'.repo_id = '.$GLOBALS['xoopsDB']->prefix('wggithub_readmes').'.rm_repoid '; |
|
271 | + $sql .= 'SET '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').'.repo_readme = 1 '; |
|
272 | + $sql .= 'WHERE ((('.$GLOBALS['xoopsDB']->prefix('wggithub_readmes').'.rm_id)>0));'; |
|
273 | 273 | $GLOBALS['xoopsDB']->queryF($sql); |
274 | 274 | |
275 | 275 | return true; |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | if (Constants::STATUS_NEW === $repoStatus || Constants::STATUS_UPDATED === $repoStatus || 0 == $releasesCount) { |
150 | 150 | $ghReleases = $githubClient->getReleases($repositoriesAll[$i]->getVar('repo_user'), $repositoriesAll[$i]->getVar('repo_name')); |
151 | 151 | if ($releasesCount > 0) { |
152 | - $sql = 'DELETE FROM `' . $GLOBALS['xoopsDB']->prefix('wggithub_releases') . '` WHERE `rel_repoid` = ' . $repoId; |
|
152 | + $sql = 'DELETE FROM `'.$GLOBALS['xoopsDB']->prefix('wggithub_releases').'` WHERE `rel_repoid` = '.$repoId; |
|
153 | 153 | if (!$result = $GLOBALS['xoopsDB']->queryF($sql)) { |
154 | 154 | return false; |
155 | 155 | } |
@@ -159,13 +159,13 @@ discard block |
||
159 | 159 | $first = true; |
160 | 160 | $final = false; |
161 | 161 | foreach ($ghReleases as $ghRelease) { |
162 | - if ($first || (!$final && !(bool)$ghRelease['prerelease'])) { |
|
162 | + if ($first || (!$final && !(bool) $ghRelease['prerelease'])) { |
|
163 | 163 | // save first in any case and save first final version |
164 | 164 | $releasesObj = $releasesHandler->create(); |
165 | 165 | $releasesObj->setVar('rel_repoid', $repoId); |
166 | 166 | $releasesObj->setVar('rel_type', $ghRelease['type']); |
167 | 167 | $releasesObj->setVar('rel_name', $ghRelease['name']); |
168 | - $releasesObj->setVar('rel_prerelease', (true == (bool)$ghRelease['prerelease'])); |
|
168 | + $releasesObj->setVar('rel_prerelease', (true == (bool) $ghRelease['prerelease'])); |
|
169 | 169 | $releasesObj->setVar('rel_publishedat', \strtotime($ghRelease['published_at'])); |
170 | 170 | $releasesObj->setVar('rel_tarballurl', $ghRelease['tarball_url']); |
171 | 171 | $releasesObj->setVar('rel_zipballurl', $ghRelease['zipball_url']); |
@@ -177,7 +177,7 @@ discard block |
||
177 | 177 | } |
178 | 178 | } |
179 | 179 | $first = false; |
180 | - if (false === (bool)$ghRelease['prerelease']) { |
|
180 | + if (false === (bool) $ghRelease['prerelease']) { |
|
181 | 181 | $final = true; |
182 | 182 | } |
183 | 183 | } |
@@ -215,7 +215,7 @@ discard block |
||
215 | 215 | // must return true otherwise releases will not be loaded |
216 | 216 | return true; |
217 | 217 | } |
218 | - $sql = 'DELETE FROM `' . $GLOBALS['xoopsDB']->prefix('wggithub_releases') . '` WHERE `rel_repoid` = ' . $repoId; |
|
218 | + $sql = 'DELETE FROM `'.$GLOBALS['xoopsDB']->prefix('wggithub_releases').'` WHERE `rel_repoid` = '.$repoId; |
|
219 | 219 | if (!$result = $GLOBALS['xoopsDB']->queryF($sql)) { |
220 | 220 | return false; |
221 | 221 | } |
@@ -224,13 +224,13 @@ discard block |
||
224 | 224 | $first = true; |
225 | 225 | $final = false; |
226 | 226 | foreach ($ghReleases as $ghRelease) { |
227 | - if ($first || (!$final && !(bool)$ghRelease['prerelease'])) { |
|
227 | + if ($first || (!$final && !(bool) $ghRelease['prerelease'])) { |
|
228 | 228 | // save first in any case and save first final version |
229 | 229 | $releasesObj = $releasesHandler->create(); |
230 | 230 | $releasesObj->setVar('rel_repoid', $repoId); |
231 | 231 | $releasesObj->setVar('rel_type', $ghRelease['type']); |
232 | 232 | $releasesObj->setVar('rel_name', $ghRelease['name']); |
233 | - $releasesObj->setVar('rel_prerelease', (true == (bool)$ghRelease['prerelease'])); |
|
233 | + $releasesObj->setVar('rel_prerelease', (true == (bool) $ghRelease['prerelease'])); |
|
234 | 234 | $releasesObj->setVar('rel_publishedat', \strtotime($ghRelease['published_at'])); |
235 | 235 | $releasesObj->setVar('rel_tarballurl', $ghRelease['tarball_url']); |
236 | 236 | $releasesObj->setVar('rel_zipballurl', $ghRelease['zipball_url']); |
@@ -242,7 +242,7 @@ discard block |
||
242 | 242 | } |
243 | 243 | } |
244 | 244 | $first = false; |
245 | - if (false === (bool)$ghRelease['prerelease']) { |
|
245 | + if (false === (bool) $ghRelease['prerelease']) { |
|
246 | 246 | $final = true; |
247 | 247 | } |
248 | 248 | } |
@@ -259,17 +259,17 @@ discard block |
||
259 | 259 | public function updateRepoReleases() |
260 | 260 | { |
261 | 261 | // update repo_prerelease |
262 | - $sql = 'UPDATE ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . ' INNER JOIN ' . $GLOBALS['xoopsDB']->prefix('wggithub_releases'); |
|
263 | - $sql .= ' ON ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . '.repo_id = ' . $GLOBALS['xoopsDB']->prefix('wggithub_releases') . '.rel_repoid '; |
|
264 | - $sql .= 'SET ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . '.repo_prerelease = 1 '; |
|
265 | - $sql .= 'WHERE (((' . $GLOBALS['xoopsDB']->prefix('wggithub_releases') . '.rel_prerelease)=1));'; |
|
262 | + $sql = 'UPDATE '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').' INNER JOIN '.$GLOBALS['xoopsDB']->prefix('wggithub_releases'); |
|
263 | + $sql .= ' ON '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').'.repo_id = '.$GLOBALS['xoopsDB']->prefix('wggithub_releases').'.rel_repoid '; |
|
264 | + $sql .= 'SET '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').'.repo_prerelease = 1 '; |
|
265 | + $sql .= 'WHERE ((('.$GLOBALS['xoopsDB']->prefix('wggithub_releases').'.rel_prerelease)=1));'; |
|
266 | 266 | $GLOBALS['xoopsDB']->queryF($sql); |
267 | 267 | |
268 | 268 | // update repo_release |
269 | - $sql = 'UPDATE ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . ' INNER JOIN ' . $GLOBALS['xoopsDB']->prefix('wggithub_releases'); |
|
270 | - $sql .= ' ON ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . '.repo_id = ' . $GLOBALS['xoopsDB']->prefix('wggithub_releases') . '.rel_repoid '; |
|
271 | - $sql .= 'SET ' . $GLOBALS['xoopsDB']->prefix('wggithub_repositories') . '.repo_release = 1 '; |
|
272 | - $sql .= 'WHERE (((' . $GLOBALS['xoopsDB']->prefix('wggithub_releases') . '.rel_prerelease)=0));'; |
|
269 | + $sql = 'UPDATE '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').' INNER JOIN '.$GLOBALS['xoopsDB']->prefix('wggithub_releases'); |
|
270 | + $sql .= ' ON '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').'.repo_id = '.$GLOBALS['xoopsDB']->prefix('wggithub_releases').'.rel_repoid '; |
|
271 | + $sql .= 'SET '.$GLOBALS['xoopsDB']->prefix('wggithub_repositories').'.repo_release = 1 '; |
|
272 | + $sql .= 'WHERE ((('.$GLOBALS['xoopsDB']->prefix('wggithub_releases').'.rel_prerelease)=0));'; |
|
273 | 273 | $GLOBALS['xoopsDB']->queryF($sql); |
274 | 274 | |
275 | 275 | return true; |