Skip to content

Commit 8709ce9

Browse files
committed
Fix: Allow save of new Form plugin
1 parent e4afe18 commit 8709ce9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

djangocms_form_builder/forms.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ class Meta:
169169
)
170170

171171
def __init__(self, *args, **kwargs):
172-
if not _form_registry and "instance" in kwargs:
172+
if not _form_registry and "instance" in kwargs and kwargs["instance"] is not None:
173173
# remove form_selection data if widget will be hidden
174174
kwargs["instance"].form_selection = ""
175175

0 commit comments

Comments
 (0)