Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/wp-conte.../plugins/sitepres.../res/js/shared
File: wpml-template-compiler.js
/**
[0] Fix | Delete
*
[1] Fix | Delete
* @param usInstance Object an instance of underscore
[2] Fix | Delete
* @param templates Object a hash containing templates as arrays of html strings
[3] Fix | Delete
* @returns {{getTemplate: getTemplate}}
[4] Fix | Delete
* @constructor
[5] Fix | Delete
*/
[6] Fix | Delete
var WpmlTemplateCompiler = function (usInstance, templates) {
[7] Fix | Delete
var compiledTemplates = {};
[8] Fix | Delete
[9] Fix | Delete
return {
[10] Fix | Delete
/**
[11] Fix | Delete
*
[12] Fix | Delete
* @param {string} temp
[13] Fix | Delete
* @returns {*|false} compiled underscore template if a template for the given
[14] Fix | Delete
* index was found, false if no such template exists
[15] Fix | Delete
*/
[16] Fix | Delete
getTemplate: function (temp) {
[17] Fix | Delete
if (!templates.hasOwnProperty(temp)) {
[18] Fix | Delete
throw 'No such template: ' + temp;
[19] Fix | Delete
}
[20] Fix | Delete
if (compiledTemplates[temp] === undefined) {
[21] Fix | Delete
var template = templates[temp];
[22] Fix | Delete
if (template instanceof Array) {
[23] Fix | Delete
template = template.join("\n");
[24] Fix | Delete
}
[25] Fix | Delete
compiledTemplates[temp] = usInstance.template(template);
[26] Fix | Delete
}
[27] Fix | Delete
return compiledTemplates[temp];
[28] Fix | Delete
}
[29] Fix | Delete
};
[30] Fix | Delete
};
[31] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function