Rev 1278 | Rev 1375 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1278 | Rev 1293 | ||
---|---|---|---|
Line 47... | Line 47... | ||
47 | private function getSvnCommand(): string { |
47 | private function getSvnCommand(): string { |
48 | return 'svn update --accept theirs-full'; |
48 | return 'svn update --accept theirs-full'; |
49 | } |
49 | } |
50 | 50 | ||
51 | /** |
51 | /** |
52 | * @param string $actionID |
- | |
53 | * @param array $params |
52 | * @param array $params |
54 | * @return array |
53 | * @return array |
55 | * @throws OIDplusException |
54 | * @throws OIDplusException |
56 | */ |
55 | */ |
57 | public function action(string $actionID, array $params): array { |
56 | private function action_Update(array $params): array { |
58 | if ($actionID == 'update_now') { |
- | |
59 | @set_time_limit(0); |
57 | @set_time_limit(0); |
60 | 58 | ||
61 | if (!OIDplus::authUtils()->isAdminLoggedIn()) { |
59 | if (!OIDplus::authUtils()->isAdminLoggedIn()) { |
62 | throw new OIDplusHtmlException(_L('You need to <a %1>log in</a> as administrator.',OIDplus::gui()->link('oidplus:login$admin')), null, 401); |
60 | throw new OIDplusHtmlException(_L('You need to <a %1>log in</a> as administrator.',OIDplus::gui()->link('oidplus:login$admin')), null, 401); |
63 | } |
61 | } |
Line 171... | Line 169... | ||
171 | } |
169 | } |
172 | } |
170 | } |
173 | else { |
171 | else { |
174 | throw new OIDplusException(_L('Multiple version files/directories (oidplus_version.txt, .version.php, .git, or .svn) are existing! Therefore, the version is ambiguous!')); |
172 | throw new OIDplusException(_L('Multiple version files/directories (oidplus_version.txt, .version.php, .git, or .svn) are existing! Therefore, the version is ambiguous!')); |
175 | } |
173 | } |
- | 174 | } |
|
- | 175 | ||
- | 176 | /** |
|
- | 177 | * @param string $actionID |
|
- | 178 | * @param array $params |
|
- | 179 | * @return array |
|
- | 180 | * @throws OIDplusException |
|
- | 181 | */ |
|
- | 182 | public function action(string $actionID, array $params): array { |
|
- | 183 | if ($actionID == 'update_now') { |
|
- | 184 | return $this->action_Update($params); |
|
176 | } else { |
185 | } else { |
177 | return parent::action($actionID, $params); |
186 | return parent::action($actionID, $params); |
178 | } |
187 | } |
179 | } |
188 | } |
180 | 189 |