1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Fixes #3953: Fix validation error when creating child devices

This commit is contained in:
Jeremy Stretch
2020-01-17 14:22:58 -05:00
parent c6eb40daa8
commit 439fa731ba
2 changed files with 2 additions and 1 deletions

View File

@@ -1464,7 +1464,7 @@ class Device(ChangeLoggedModel, ConfigContextModel, CustomFieldModel):
try:
# Child devices cannot be assigned to a rack face/unit
if self.device_type.is_child_device and self.face is not None:
if self.device_type.is_child_device and self.face:
raise ValidationError({
'face': "Child device types cannot be assigned to a rack face. This is an attribute of the "
"parent device."