Moved functions out of boot.php into class

- z_root() => $a->getBaseURL()
- absurl() => removed because no usage
- is_ajax() => $a->isAjax()
- current_load() => System::currentLoad()
- argc() => $a->argc
- argv($x) => $a->getArgumentValue($x)
This commit is contained in:
Philipp Holzer 2018-10-13 18:57:31 +02:00
parent 14e7686df4
commit 2c541afd47
No known key found for this signature in database
GPG key ID: 517BE60E2CE5C8A5
8 changed files with 66 additions and 90 deletions

View file

@ -26,7 +26,7 @@ function viewsrc_content(App $a)
$item = Item::selectFirst(['body'], ['uid' => local_user(), 'id' => $item_id]);
if (DBA::isResult($item)) {
if (is_ajax()) {
if ($a->isAjax()) {
echo str_replace("\n", '<br />', $item['body']);
killme();
} else {