allow restrictions to stateless url queries

This commit is contained in:
Chris Caron
2024-09-02 22:27:25 -04:00
parent f87f4c3471
commit 57be58ae43
4 changed files with 35 additions and 20 deletions

View File

@@ -1363,13 +1363,17 @@ class StatelessNotifyView(View):
kwargs = {
# Load our dynamic plugin path
'plugin_paths': settings.APPRISE_PLUGIN_PATHS,
# Load our persistent storage path
'storage_path': settings.APPRISE_STORAGE_DIR,
# Our storage URL ID Length
'storage_idlen': settings.APPRISE_STORAGE_UID_LENGTH,
# Define if we flush to disk as soon as possible or not when required
'storage_mode': settings.APPRISE_STORAGE_MODE,
}
if settings.APPRISE_STATELESS_STORAGE:
# Persistent Storage is allowed with Stateless queries
kwargs.update({
# Load our persistent storage path
'storage_path': settings.APPRISE_STORAGE_DIR,
# Our storage URL ID Length
'storage_idlen': settings.APPRISE_STORAGE_UID_LENGTH,
# Define if we flush to disk as soon as possible or not when required
'storage_mode': settings.APPRISE_STORAGE_MODE,
})
if body_format:
# Store our defined body format