Add function as method of to be stric mode compilant
This commit is contained in:
parent
a0126f6a15
commit
79820a0f05
@ -75,7 +75,7 @@ ResourceLocator.prototype.getUrls = function(username, resourcePath) {
|
||||
}
|
||||
};
|
||||
|
||||
function urlForTemplate(tpl, username, cdnDomain, resource, templated) {
|
||||
ResourceLocator.prototype.urlForTemplate = function (tpl, username, cdnDomain, resource, templated) {
|
||||
cdnDomain = cdnDomain || {};
|
||||
if (templated) {
|
||||
return {
|
||||
@ -109,10 +109,10 @@ ResourceLocator.prototype.getUrlsFromTemplate = function(username, resource, tem
|
||||
var urls = {};
|
||||
var cdnDomain = getCdnDomain(this.environment.serverMetadata, resource) || {};
|
||||
if (this.resourcesUrlTemplates.http) {
|
||||
urls.http = urlForTemplate(this.resourcesUrlTemplates.http, username, cdnDomain.http, resource, templated);
|
||||
urls.http = this.urlForTemplate(this.resourcesUrlTemplates.http, username, cdnDomain.http, resource, templated);
|
||||
}
|
||||
if (this.resourcesUrlTemplates.https) {
|
||||
urls.https = urlForTemplate(this.resourcesUrlTemplates.https, username, cdnDomain.https, resource, templated);
|
||||
urls.https = this.urlForTemplate(this.resourcesUrlTemplates.https, username, cdnDomain.https, resource, templated);
|
||||
}
|
||||
|
||||
return urls;
|
||||
|
Loading…
Reference in New Issue
Block a user