Hi Alex,
Sorry that I didn´t see it before, but JSONModel does not have metadata! So there is of course no function metadataLoaded. So the logic has to be completely different.
EDIT: ok, there is a kind of metadata but function does not exist for JSON model only for oDataModel.
Best regards,
Sebastian