From f8c4470d98f103bfb1851a3f66a609be72318d50 Mon Sep 17 00:00:00 2001 From: Matthias Date: Thu, 20 Jan 2022 23:51:42 +0100 Subject: [PATCH] make simpler --- InvenTree/part/models.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/InvenTree/part/models.py b/InvenTree/part/models.py index fde9c80720..1566c1a9f0 100644 --- a/InvenTree/part/models.py +++ b/InvenTree/part/models.py @@ -2188,9 +2188,7 @@ def after_save_part(sender, instance: Part, created, **kwargs): Function to be executed after a Part is saved """ - if created: - pass - else: + if not created: # Check part stock only if we are *updating* the part (not creating it) # Run this check in the background