Explorar el Código

Use outstanding isArray function in new render config object code

pull/764/head
Sophie Kirschner hace 5 años
padre
commit
6726b91345
Se han modificado 3 ficheros con 5 adiciones y 5 borrados
  1. +2
    -2
      mustache.js
  2. +1
    -1
      mustache.min.js
  3. +2
    -2
      mustache.mjs

+ 2
- 2
mustache.js Ver fichero

@@ -679,7 +679,7 @@
}; };


Writer.prototype.getConfigTags = function getConfigTags (config) { Writer.prototype.getConfigTags = function getConfigTags (config) {
if (Array.isArray(config)) {
if (isArray(config)) {
return config; return config;
} }
else if (config && typeof config === 'object') { else if (config && typeof config === 'object') {
@@ -691,7 +691,7 @@
}; };


Writer.prototype.getConfigEscape = function getConfigEscape (config) { Writer.prototype.getConfigEscape = function getConfigEscape (config) {
if (config && typeof config === 'object' && !Array.isArray(config)) {
if (config && typeof config === 'object' && !isArray(config)) {
return config.escape; return config.escape;
} }
else { else {


+ 1
- 1
mustache.min.js
La diferencia del archivo ha sido suprimido porque es demasiado grande
Ver fichero


+ 2
- 2
mustache.mjs Ver fichero

@@ -672,7 +672,7 @@ Writer.prototype.rawValue = function rawValue (token) {
}; };


Writer.prototype.getConfigTags = function getConfigTags (config) { Writer.prototype.getConfigTags = function getConfigTags (config) {
if (Array.isArray(config)) {
if (isArray(config)) {
return config; return config;
} }
else if (config && typeof config === 'object') { else if (config && typeof config === 'object') {
@@ -684,7 +684,7 @@ Writer.prototype.getConfigTags = function getConfigTags (config) {
}; };


Writer.prototype.getConfigEscape = function getConfigEscape (config) { Writer.prototype.getConfigEscape = function getConfigEscape (config) {
if (config && typeof config === 'object' && !Array.isArray(config)) {
if (config && typeof config === 'object' && !isArray(config)) {
return config.escape; return config.escape;
} }
else { else {


Cargando…
Cancelar
Guardar