MAPG-191 don't create separate variable for data where not necessary

This commit is contained in:
bence committed 2020-07-05 00:58:03 +02:00
1 parent e17cf68007
commit 6db6208896
8 files changed
+170 -132

No files matched your search

+2 -1
View File
@@ -26,8 +26,9 @@ if ($match !== null) {
}
if ($method === 'post' && Container::$request->post('anti_csrf_token') !== Container::$request->session()->get('anti_csrf_token')) {
$content = new MapGuesser\Response\JsonContent(['error' => 'no_valid_anti_csrf_token']);
header('Content-Type: text/html; charset=UTF-8', true, 403);
echo json_encode(['error' => 'no_valid_anti_csrf_token']);
$content->render();
return;
}