aboutsummaryrefslogtreecommitdiffstats
path: root/src/slskd/Integrations/Scripts/ScriptService.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/slskd/Integrations/Scripts/ScriptService.cs')
-rw-r--r--src/slskd/Integrations/Scripts/ScriptService.cs9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/slskd/Integrations/Scripts/ScriptService.cs b/src/slskd/Integrations/Scripts/ScriptService.cs
index 3a05df04..dacead33 100644
--- a/src/slskd/Integrations/Scripts/ScriptService.cs
+++ b/src/slskd/Integrations/Scripts/ScriptService.cs
@@ -121,7 +121,7 @@ public class ScriptService
},
};
}
- else if (run.ArgsList is not null)
+ else if (run.Arglist is not null)
{
// 'args list' mode takes precedence over 'args' mode
// the supplied list of args will be passed to the constructor of ProcessStartInfo, which is
@@ -134,7 +134,7 @@ public class ScriptService
{
StartInfo = new ProcessStartInfo(
fileName: executable,
- arguments: run.ArgsList)
+ arguments: run.Arglist)
{
WorkingDirectory = Program.ScriptDirectory,
UseShellExecute = false,
@@ -164,7 +164,7 @@ public class ScriptService
};
}
- Log.Debug("Running script '{Script}': \"{Executable}\" {Args} (id: {ProcessId})", script.Key, executable, run.Args ?? string.Join(' ', run.ArgsList ?? []), processId);
+ Log.Debug("Running script '{Script}': \"{Executable}\" {Args} (id: {ProcessId})", script.Key, executable, run.Args ?? string.Join(' ', run.Arglist ?? []), processId);
var sw = Stopwatch.StartNew();
process.StartInfo.EnvironmentVariables["SLSKD_SCRIPT_DATA"] = data.ToJson();
@@ -187,7 +187,8 @@ public class ScriptService
}
catch (Exception ex)
{
- Log.Warning(ex, "Failed to run script '{Script}' for event type {Event}: {Message} (id: {ProcessId})", script.Key, data.Type, ex.Message, processId);
+ Log.Warning("Failed to run script '{Script}' for event type {Event}: {Message} (id: {ProcessId})", script.Key, data.Type, ex.Message, processId);
+ Log.Debug(ex, "Failed to run script '{Script}' for event type {Event}: {Message} (id: {ProcessId})", script.Key, data.Type, ex.Message, processId);
}
finally
{