Removing elements in a JsonArray

UPDATE default USE KEYS "theDatabase"
SET theArray = ARRAY item FOR item IN theArray WHEN item.field1 IS MISSING END