mirror of
https://github.com/Kozea/Radicale.git
synced 2025-08-10 18:40:53 +00:00
log in case delete of collection is prevented
This commit is contained in:
parent
d15e836079
commit
40c8b3d038
1 changed files with 2 additions and 0 deletions
|
@ -25,6 +25,7 @@ from typing import Optional
|
|||
from radicale import httputils, storage, types, xmlutils
|
||||
from radicale.app.base import Access, ApplicationBase
|
||||
from radicale.hook import HookNotificationItem, HookNotificationItemTypes
|
||||
from radicale.log import logger
|
||||
|
||||
|
||||
def xml_delete(base_prefix: str, path: str, collection: storage.BaseCollection,
|
||||
|
@ -82,6 +83,7 @@ class ApplicationPartDelete(ApplicationBase):
|
|||
)
|
||||
xml_answer = xml_delete(base_prefix, path, item)
|
||||
else:
|
||||
logger.info("delete of collection is prevented by config/option [rights] permit_delete_collection: %s", path)
|
||||
return httputils.NOT_ALLOWED
|
||||
else:
|
||||
assert item.collection is not None
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue