var resources = Object.prototype.toString.call(resources) == "[object Array]" ? resources : []; resources.Loading = 'Loading...';