diff options
author | Frank Karlitschek <frank@owncloud.org> | 2012-05-03 12:23:29 +0200 |
---|---|---|
committer | Frank Karlitschek <frank@owncloud.org> | 2012-05-03 12:23:29 +0200 |
commit | 43caa3b3b9cc9dbbf73ab2f6695a801a07a1dba5 (patch) | |
tree | f4b191f0d039cb7de942554ea23df3fff9de7ad6 /apps/contacts/ajax/currentphoto.php | |
parent | 375ba986452b190745b9388be92737d7e5771673 (diff) | |
download | nextcloud-server-43caa3b3b9cc9dbbf73ab2f6695a801a07a1dba5.tar.gz nextcloud-server-43caa3b3b9cc9dbbf73ab2f6695a801a07a1dba5.zip |
ported oc_json
Diffstat (limited to 'apps/contacts/ajax/currentphoto.php')
-rwxr-xr-x | apps/contacts/ajax/currentphoto.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/apps/contacts/ajax/currentphoto.php b/apps/contacts/ajax/currentphoto.php index 488f064836b..d8afa060b1e 100755 --- a/apps/contacts/ajax/currentphoto.php +++ b/apps/contacts/ajax/currentphoto.php @@ -24,11 +24,11 @@ // Check if we are a user // Firefox and Konqueror tries to download application/json for me. --Arthur -OC_JSON::setContentTypeHeader('text/plain'); -OC_JSON::checkLoggedIn(); -OC_JSON::checkAppEnabled('contacts'); +OCP\JSON::setContentTypeHeader('text/plain'); +OCP\JSON::checkLoggedIn(); +OCP\JSON::checkAppEnabled('contacts'); function bailOut($msg) { - OC_JSON::error(array('data' => array('message' => $msg))); + OCP\JSON::error(array('data' => array('message' => $msg))); OCP\Util::writeLog('contacts','ajax/currentphoto.php: '.$msg, OCP\Util::ERROR); exit(); } @@ -55,7 +55,7 @@ if( is_null($contact)) { } if($image->valid()) { if($image->save($tmpfname)) { - OC_JSON::success(array('data' => array('id'=>$_GET['id'], 'tmp'=>$tmpfname))); + OCP\JSON::success(array('data' => array('id'=>$_GET['id'], 'tmp'=>$tmpfname))); exit(); } else { bailOut(OC_Contacts_App::$l10n->t('Error saving temporary file.')); |