diff --git a/netbox/extras/jobs.py b/netbox/extras/jobs.py index 45686b001..733654198 100644 --- a/netbox/extras/jobs.py +++ b/netbox/extras/jobs.py @@ -41,8 +41,7 @@ class ScriptJob(JobRunner): try: # A script can modify multiple models so need to do an atomic lock on # both the default database (for non ChangeLogged models) and potentially - # any other database (for ChangeLogged models) - choosing Device as - # the model to use as it has ChangeLoggingMixin + # any other database (for ChangeLogged models) with transaction.atomic(): script.output = script.run(data, commit) if not commit: