summaryrefslogtreecommitdiff
path: root/public/edit/index.php
diff options
context:
space:
mode:
Diffstat (limited to 'public/edit/index.php')
-rw-r--r--public/edit/index.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/public/edit/index.php b/public/edit/index.php
index fba5a90..b1efeec 100644
--- a/public/edit/index.php
+++ b/public/edit/index.php
@@ -4,6 +4,7 @@ declare(strict_types=1);
use DTS\BookmarkRepository;
use DTS\Errors;
+use DTS\Old;
use DTS\Session;
use DTS\Template;
@@ -19,6 +20,8 @@ if (filter_input(INPUT_SERVER, 'REQUEST_METHOD') !== 'GET') {
respondAndExit(405, 'Method Not Allowed');
}
+$old = $session->get('old', new Old());
+
$errors = $session->get('errors', new Errors());
$id = filter_input(INPUT_GET, 'id');
@@ -35,7 +38,8 @@ if ($bookmark === null) {
$html = $template->render('edit', compact(
'bookmark',
- 'errors'
+ 'errors',
+ 'old'
));
respondAndExit(200, 'OK', $html);