summaryrefslogtreecommitdiff
path: root/lib/notes/delete.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/notes/delete.php')
-rw-r--r--lib/notes/delete.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/notes/delete.php b/lib/notes/delete.php
index 43dbf44..179f788 100644
--- a/lib/notes/delete.php
+++ b/lib/notes/delete.php
@@ -3,7 +3,7 @@
assert_redir(count($args) >= 3, 'notes');
$noteid = intval($args[2]);
-$note = mysql_fetch_assoc(sql("SELECT owner FROM notes WHERE id = $noteid"));
+$note = sql("SELECT owner FROM notes WHERE id = $noteid")->fetch();
assert_error($note && ($note['owner'] == $user['id'] || $user['priv'] >= $priv_admin),
"This note does not exist, or you are not allowed to delete it.");