Commit 61546873 authored by Kostis Trantzas's avatar Kostis Trantzas
Browse files

Also including the single quote escaping for backwards compatibility

parent bd7b13c0
Loading
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -155,6 +155,7 @@ export class BlocklyJavaService {
      // TODO: This is a quick hack.  Replace with goog.string.quote
      s = s.replace(/\\/g, '\\\\')
        .replace(/\n/g, '\\\n')
        .replace(/'/g, '\\\'')
        .replace(/"/g, '\\"');
      return '"' + s + '"';
    };