serialize text nodes correctly

This commit is contained in:
ansuz
2016-04-20 10:10:26 +02:00
parent 302b8c5f04
commit df22c246c4
3 changed files with 12 additions and 4 deletions

View File

@@ -24,7 +24,8 @@ define([], function () {
return callOnHyperJSON(child, cb);
} else if (typeof (child) === 'string') {
// string nodes have leading and trailing quotes
return child.replace(/(^"|"$)/g,"");
// don't strip them!
return child; //child.replace(/(^"|"$)/g,"");
} else {
// the above branches should cover all methods
// if we hit this, there is a problem