diff options
author | Andrew Dolgov <[email protected]> | 2009-12-17 13:31:12 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2009-12-17 13:31:12 +0300 |
commit | b792cd703ac554c611891b0f1a092034813c9b7c (patch) | |
tree | 0f12d38c60e30c56c9952f34285d9bee5b784d2b /api/index.php | |
parent | 68539f8b55a26e4c9edbfa7174db5739fc35ce63 (diff) |
api: return error on unknown method
Diffstat (limited to 'api/index.php')
-rw-r--r-- | api/index.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/api/index.php b/api/index.php index d3b5ff4fe..5c1efd15e 100644 --- a/api/index.php +++ b/api/index.php @@ -364,6 +364,11 @@ $pref_name = db_escape_string($_REQUEST["pref_name"]); print json_encode(array("value" => get_pref($link, $pref_name))); break; + + default: + print json_encode(array("error" => 'UNKNOWN_METHOD')); + break; + } db_close($link); |