nunaliit2-couch-application: Detect documents with invalid structure.

nunaliit2-js: Fix issue where nunaliit_last_updated.action is not set to
"updated"