Comparing version 0.5.20 to 0.5.21
@@ -40,5 +40,9 @@ var util = require('util'), | ||
parsed = parser.parse(contents); | ||
try{ | ||
parsed = parser.parse(contents); | ||
}catch(e){ | ||
return callback(e); | ||
} | ||
mu.cache[filename] = [parsed, unique]; | ||
var i = 0; | ||
@@ -45,0 +49,0 @@ (function next(err) { |
@@ -67,3 +67,3 @@ var util = require('util'), | ||
if (content !== '') { | ||
buffer.write(content, 'utf8', 0); | ||
buffer.write(content); | ||
this.appendMultiContent(content); | ||
@@ -70,0 +70,0 @@ this.tokens.push(['static', content, buffer]); |
{ "name": "mu2" | ||
, "description": "A Mustache template engine for Node.js" | ||
, "keywords": ["template", "mustache"] | ||
, "version" : "0.5.20" | ||
, "version" : "0.5.21" | ||
, "homepage": "http://github.com/raycmorgan/mu" | ||
, "author" : "RayMorgan <ray@rumgr.com>" | ||
, "main" : "lib/mu", | ||
"licenses": [ | ||
{ | ||
"type": "MIT", | ||
"url": "https://raw.github.com/raycmorgan/Mu/master/LICENSE" | ||
} | ||
] | ||
"license": "MIT" | ||
} |
@@ -39,3 +39,3 @@ # Mu - a fast, streaming Node.js Mustache engine | ||
var stream = mu.compileAndRender('index.html', {name: "john"}); | ||
util.pump(stream, res); | ||
stream.pipe(res); | ||
@@ -42,0 +42,0 @@ }).listen(8000); |
var fs = require('fs'), | ||
path = require('path'), | ||
mu = require('../lib/mu'), | ||
pump = require('util').pump; | ||
mu = require('../lib/mu'); | ||
@@ -25,3 +24,3 @@ mu.root = path.join(__dirname, 'examples'); | ||
pump(mu.render('complex.html', js), process.stdout); | ||
mu.render('complex.html', js).pipe(process.stdout); | ||
@@ -28,0 +27,0 @@ var i = 0, d = new Date(); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
783
77850