diff options
author | Chad Kieffer <ckieffer@227.1.241.10.in-addr.arpa> | 2010-06-14 14:43:14 -0400 |
---|---|---|
committer | Chad Kieffer <ckieffer@227.1.241.10.in-addr.arpa> | 2010-06-14 14:43:14 -0400 |
commit | 3c6e710aa75b309fd7ff50aa8f5c58721b17770f (patch) | |
tree | 062b516f3fad5921e4ace326fa6b2f7f868ca87e /modules/rest | |
parent | 782c1e0ae0bc597629abcd88f844d863da45901a (diff) | |
parent | 793780daa7665f7f86994235c4263fcb63554eb8 (diff) |
Merge branch 'master' of github.com:gallery/gallery3
Diffstat (limited to 'modules/rest')
-rw-r--r-- | modules/rest/helpers/rest.php | 3 | ||||
-rw-r--r-- | modules/rest/helpers/rest_event.php | 7 |
2 files changed, 10 insertions, 0 deletions
diff --git a/modules/rest/helpers/rest.php b/modules/rest/helpers/rest.php index 72927c71..3229330a 100644 --- a/modules/rest/helpers/rest.php +++ b/modules/rest/helpers/rest.php @@ -18,9 +18,12 @@ * Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ class rest_Core { + const API_VERSION = "3.0"; + static function reply($data=array()) { Session::instance()->abort_save(); + header("X-Gallery-API-Version: " . rest::API_VERSION); if (Input::instance()->get("output") == "html") { header("Content-type: text/html"); if ($data) { diff --git a/modules/rest/helpers/rest_event.php b/modules/rest/helpers/rest_event.php index e4e53ef6..f23b9a58 100644 --- a/modules/rest/helpers/rest_event.php +++ b/modules/rest/helpers/rest_event.php @@ -29,6 +29,13 @@ class rest_event { ->execute(); } + + static function change_provider($new_provider) { + db::build() + ->delete("user_access_keys") + ->execute(); + } + /** * Called after a user has been added. Just add a remote access key * on every add. |