Skip to content

Commit 6422340

Browse files
committed
Fixes #16123: Fix custom script execution via REST API
1 parent c95dd0b commit 6422340

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

netbox/extras/api/views.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,9 +240,9 @@ def post(self, request, pk):
240240
raise RQWorkerNotRunningException()
241241

242242
if input_serializer.is_valid():
243-
script.result = Job.enqueue(
243+
Job.enqueue(
244244
run_script,
245-
instance=script.module,
245+
instance=script,
246246
name=script.python_class.class_name,
247247
user=request.user,
248248
data=input_serializer.data['data'],

0 commit comments

Comments
 (0)