]> dev.renevier.net Git - syp.git/commitdiff
fixes: admin cannot modify other users items
authorarno <arenevier@fdn.fr>
Sun, 16 Aug 2009 21:02:38 +0000 (23:02 +0200)
committerarno <arenevier@fdn.fr>
Sun, 16 Aug 2009 21:59:11 +0000 (23:59 +0200)
api.php

diff --git a/api.php b/api.php
index fda62ff32389e1a630759a43e5d3643b9b44d29e..9b268dcaf31beb8ac4bbc0e4e7b577c9d44909fc 100644 (file)
--- a/api.php
+++ b/api.php
@@ -239,7 +239,7 @@ function main ($con) {
             if (!isset ($feature)) {
                 error_unreferenced ($id);
             }
-            if ($feature->user != $user) {
+            if (($feature->user != $user) && ($user != "admin")) {
                 error_unauthorized ();
             }