File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed
src/main/java/com/pusher/client Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -185,7 +185,7 @@ private PusherEvent decryptMessage(String message) {
185185 encryptedReceivedData .getCiphertext (),
186186 encryptedReceivedData .getNonce ());
187187
188- receivedMessage .replace ("data" , decryptedData );
188+ receivedMessage .put ("data" , decryptedData );
189189
190190 return new PusherEvent (receivedMessage );
191191 }
Original file line number Diff line number Diff line change 88
99import javax .net .ssl .SSLContext ;
1010import javax .net .ssl .SSLException ;
11+ import javax .net .ssl .SSLParameters ;
1112import javax .net .ssl .SSLSocketFactory ;
1213
1314import org .java_websocket .client .WebSocketClient ;
@@ -89,4 +90,14 @@ public void onError(final Exception ex) {
8990 public void removeWebSocketListener () {
9091 webSocketListener = null ;
9192 }
93+
94+ @ Override
95+ protected void onSetSSLParameters (SSLParameters sslParameters ) {
96+ // https://github.com/TooTallNate/Java-WebSocket/wiki/No-such-method-error-setEndpointIdentificationAlgorithm
97+ try {
98+ super .onSetSSLParameters (sslParameters );
99+ } catch (NoSuchMethodError error ) {
100+ // if this is being called on an android device pre-24 this api isn't available
101+ }
102+ }
92103}
You can’t perform that action at this time.
0 commit comments