adjust argc check in mod/editpost + relative path in mod/message

This commit is contained in:
Jonny Tischbein 2018-09-20 14:41:52 +02:00
parent 807ad14521
commit 58f26d195f
2 changed files with 2 additions and 2 deletions

View file

@ -21,7 +21,7 @@ function editpost_content(App $a)
}
$post_id = (($a->argc > 1) ? intval($a->argv[1]) : 0);
$return_url = (($a->argc > 1) ? base64_decode($a->argv[2]) : '');
$return_url = (($a->argc > 2) ? base64_decode($a->argv[2]) : '');
if (!$post_id) {
notice(L10n::t('Item not found') . EOL);

View file

@ -92,7 +92,7 @@ function message_post(App $a)
$a->argc = 2;
$a->argv[1] = 'new';
} else {
goaway(System::baseUrl() . '/' . $a->cmd . '/' . $ret);
goaway($a->cmd . '/' . $ret);
}
}