catalog, formats should not be arrays in JS

catalog and formats are used as dictionaries, i.e. JavaScript objects,
and using arrays when no array-specific properties are used adds
unnecessary confusion