From bdff359178d6696d1934a3e350d6cd1b33282251 Mon Sep 17 00:00:00 2001 From: Aaron Parecki Date: Fri, 6 Jan 2017 11:00:17 -0800 Subject: support rich editor in logged-out mode --- controllers/editor.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'controllers/editor.php') diff --git a/controllers/editor.php b/controllers/editor.php index 0f4380b..bfe70af 100644 --- a/controllers/editor.php +++ b/controllers/editor.php @@ -1,12 +1,11 @@ get('/editor', function() use($app) { - if($user=require_login($app)) { - $html = $app->render('editor.php', [ - 'user' => $user - ]); - $app->response()->body($html); - } + $user = require_login($app, false); + $html = $app->render('editor.php', [ + 'user' => $user + ]); + $app->response()->body($html); }); $app->post('/editor/publish', function() use($app) { -- cgit v1.2.3