From 180fe602ad5cd3da53aeed7bd218e416d3831e9f Mon Sep 17 00:00:00 2001 From: Skylar Ittner Date: Tue, 15 Jan 2019 13:51:12 -0700 Subject: [PATCH] Fix copy/paste error --- api/actions/savenote.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/actions/savenote.php b/api/actions/savenote.php index 0c2ca9b..bbb6001 100644 --- a/api/actions/savenote.php +++ b/api/actions/savenote.php @@ -24,7 +24,7 @@ if (!empty($VARS['id'])) { } if ($newnote && $SETTINGS['note_limit'] !== false && !getRequestUser()->hasPermission($SETTINGS['unlimited_permission'])) { - $notecount = $database->count("notes", ['ownerid' => $_SESSION['uid']]); + $notecount = $database->count("notes", ['ownerid' => getRequestUser()->getUID()]); if ($notecount >= $SETTINGS['note_limit']) { sendJsonResp($Strings->get("You've reached your quota limit and can't make new notes.", false), "ERROR"); }