fix js parser

This commit is contained in:
j 2012-05-22 19:50:26 +02:00
parent 6fcca8f3a9
commit 57f774ae8d

View file

@ -122,10 +122,8 @@ Ox.doc = (function() {
var lines = decodeLinebreaks(str).split('\n'),
indent = getIndent(lines[1]);
return {
statement: Ox.filter(lines, function(line, i) {
return i && i < lines.length - 1;
}).map(lines, function(line, i) {
return line.substr(indent);
statement: lines.slice(1, -1).map(function(line, i) {
return line.slice(indent);
}).join('\n')
};
}