Fix Register Tags example

This commit is contained in:
ssendev
2019-03-21 20:46:21 +08:00
committed by Jun Yang
parent 84ea2c7488
commit 265534b7b7
+3 -1
View File
@@ -228,7 +228,9 @@ engine.registerTag('upper', {
},
render: function(scope, hash) {
var str = Liquid.evalValue(this.str, scope); // 'alice'
return Promise.resolve(str.toUpperCase()); // 'Alice'
return str.then(function(name) {
return name.toUpperCase() // 'Alice'
})
}
});
```