fix can-be-published

This commit is contained in:
Thomas Citharel 2016-08-14 19:18:21 +02:00 committed by Lukas Reschke
parent f0421e1f75
commit 6378dbca7e
No known key found for this signature in database
GPG Key ID: B9F6980CF6E759B1
2 changed files with 5 additions and 1 deletions

View File

@ -279,4 +279,8 @@ class Calendar extends \Sabre\CalDAV\Calendar implements IShareable {
return isset($this->calendarInfo['{http://owncloud.org/ns}owner-principal']);
}
public function isSubscription() {
return isset($this->calendarInfo['{http://calendarserver.org/ns/}source']);
}
}

View File

@ -110,7 +110,7 @@ class PublishPlugin extends ServerPlugin {
});
$propFind->handle('{'.self::NS_CALENDARSERVER.'}can-be-published', function() use ($node) {
return !$node->getPublishStatus();
return !$node->getPublishStatus() && !$node->isSubscription();
});
}
}