Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'apps/calendar/ajax/share/unshare.php')
-rwxr-xr-xapps/calendar/ajax/share/unshare.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/apps/calendar/ajax/share/unshare.php b/apps/calendar/ajax/share/unshare.php
index e5676c72f31..cbd5ed8e505 100755
--- a/apps/calendar/ajax/share/unshare.php
+++ b/apps/calendar/ajax/share/unshare.php
@@ -13,7 +13,7 @@ switch($idtype){
case 'event':
break;
default:
- OC_JSON::error(array('message'=>'unexspected parameter'));
+ OCP\JSON::error(array('message'=>'unexspected parameter'));
exit;
}
$sharewith = $_GET['sharewith'];
@@ -24,20 +24,20 @@ switch($sharetype){
case 'public':
break;
default:
- OC_JSON::error(array('message'=>'unexspected parameter'));
+ OCP\JSON::error(array('message'=>'unexspected parameter'));
exit;
}
if($sharetype == 'user' && !OCP\User::userExists($sharewith)){
- OC_JSON::error(array('message'=>'user not found'));
+ OCP\JSON::error(array('message'=>'user not found'));
exit;
}elseif($sharetype == 'group' && !OC_Group::groupExists($sharewith)){
- OC_JSON::error(array('message'=>'group not found'));
+ OCP\JSON::error(array('message'=>'group not found'));
exit;
}
$success = OC_Calendar_Share::unshare(OCP\USER::getUser(), $sharewith, $sharetype, $id, (($idtype=='calendar') ? OC_Calendar_Share::CALENDAR : OC_Calendar_Share::EVENT));
if($success){
- OC_JSON::success();
+ OCP\JSON::success();
}else{
- OC_JSON::error(array('message'=>'can not unshare'));
+ OCP\JSON::error(array('message'=>'can not unshare'));
exit;
} \ No newline at end of file