Skip to content

Commit 0c827e1

Browse files
author
Devendra
committed
adding fix for publishing json literals
1 parent 23d04c3 commit 0c827e1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

java/srcPubnubApi/com/pubnub/api/PubnubCore.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -232,6 +232,7 @@ protected Object _publish(Hashtable args, boolean sync) {
232232
}
233233
} else {
234234
if (message instanceof String) {
235+
msgStr = msgStr.replaceAll("\"", "\\\\\"");
235236
msgStr = "\"" + msgStr + "\"";
236237
}
237238
}

0 commit comments

Comments
 (0)