mirror of
https://github.com/Dispatcharr/Dispatcharr.git
synced 2026-07-18 00:55:50 +00:00
Merge pull request #1019 from Dispatcharr/integrations-fix
pass all details into event triggers, updated custom script default path
This commit is contained in:
commit
7dc01a821b
2 changed files with 7 additions and 2 deletions
|
|
@ -404,7 +404,7 @@ def dispatch_event_system(event_type, channel_id=None, channel_name=None, **deta
|
|||
from core.models import StreamProfile
|
||||
from core.utils import RedisClient
|
||||
|
||||
payload = {}
|
||||
payload = dict(details)
|
||||
|
||||
channel_obj = None
|
||||
if channel_id:
|
||||
|
|
@ -464,6 +464,11 @@ def dispatch_event_system(event_type, channel_id=None, channel_name=None, **deta
|
|||
|
||||
payload["profile_used"] = profile_used
|
||||
|
||||
# remove empty keys
|
||||
for k in list(payload.keys()):
|
||||
if not payload[k]:
|
||||
del payload[k]
|
||||
|
||||
trigger_event(event_type, payload)
|
||||
|
||||
except Exception as e:
|
||||
|
|
|
|||
|
|
@ -416,7 +416,7 @@ LOGGING = {
|
|||
|
||||
# Connect script execution safety settings
|
||||
# Allowed base directories for custom scripts; real paths must be inside
|
||||
_allowed_dirs_env = os.environ.get("DISPATCHARR_ALLOWED_SCRIPT_DIRS", "/data/plugins")
|
||||
_allowed_dirs_env = os.environ.get("DISPATCHARR_ALLOWED_SCRIPT_DIRS", "/data/scripts")
|
||||
CONNECT_ALLOWED_SCRIPT_DIRS = [p for p in _allowed_dirs_env.split(":") if p]
|
||||
|
||||
# Max execution time (seconds) for scripts
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue