Empty fields break JS
kjac opened this issue · comments
Kenn Jacobsen commented
If I have a simple text field in multiple languages, and I empty the value of the text field in all languages, the Vorto JS breaks when publishing twice in a row.
Steps:
- Open the JS console :)
- In a Vorto datatype wrapping a simple text field, clean out all values in all languages and hit save and publish.
- Hit save and publish again.
- The console logs JS errors.
I think it's the assignment of undefined
that causes the issue. If you replace undefined
with {}
, it seems to work just fine.
Dave Woestenborghs commented
I created a PR in this issue that fixes it for me #58
Matt Brailsford commented