Fixes a couple bugs: NPE on null string from unknown metadata; JS handling of empty object from unknown metadata.