From 1fa6e7512c913e358f1e8e4bdae52aadc85a2f26 Mon Sep 17 00:00:00 2001 From: Cayo Puigdefabregas Date: Fri, 15 Jul 2022 13:11:04 +0200 Subject: [PATCH] fix tag automatic only for placeholder --- ereuse_devicehub/resources/device/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ereuse_devicehub/resources/device/models.py b/ereuse_devicehub/resources/device/models.py index 0703359d..3a946b1f 100644 --- a/ereuse_devicehub/resources/device/models.py +++ b/ereuse_devicehub/resources/device/models.py @@ -1481,7 +1481,7 @@ def create_code_tag(mapper, connection, device): """ from ereuse_devicehub.resources.tag.model import Tag - if isinstance(device, Computer): + if isinstance(device, Computer) and not device.placeholder: tag = Tag(device_id=device.id, id=device.devicehub_id) db.session.add(tag)