fixed that escaping thing i think

This commit is contained in:
Peter Cottle 2012-10-20 23:20:23 -07:00
parent ea3fe2f3eb
commit 46632988cf
2 changed files with 4 additions and 3 deletions

View file

@ -274,7 +274,8 @@ OptionParser.prototype.explodeAndSet = function() {
// inside
var exploded = this.rawOptions.match(/('.*?'|".*?"|\S+)/g) || [];
_.each(exploded, function(part, i) {
exploded[i] = part.replace(/['"]/g, '');
exploded[i] = part.replace(/^['"]|['"]$/g, '');
console.log(exploded[i]);
});
for (var i = 0; i < exploded.length; i++) {