Skip to content

Commit

Permalink
Dev: Check for logged in user before saving QuickMenu sort order
Browse files Browse the repository at this point in the history
  • Loading branch information
olleharstedt committed May 10, 2016
1 parent d5d9f51 commit bb72b87
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions application/core/plugins/QuickMenu/QuickMenu.php
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,13 @@ public static function getOrder($userId)

public function newDirectRequest()
{
$user = $this->api->getCurrentUser();

if ($user === false || $user === null)
{
throw new CException("Invalid request: user is not logged in or does not exist");
}

$event = $this->event;
if ($event->get('target') == "QuickMenu")
{
Expand Down

0 comments on commit bb72b87

Please sign in to comment.