Skip to content

Commit

Permalink
Use external version of json-bigint
Browse files Browse the repository at this point in the history
  • Loading branch information
davidyuk committed Jun 21, 2020
1 parent 51c661d commit 55645a9
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 526 deletions.
6 changes: 3 additions & 3 deletions es/channel/internal.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import { w3cwebsocket as W3CWebSocket } from 'websocket'
import { EventEmitter } from 'events'
import * as R from 'ramda'
import JSONBig from '../utils/json-big'
import JsonBig from '../utils/json-big'
import { pascalToSnake } from '../utils/string'
import { awaitingConnection, awaitingReconnection, channelOpen } from './handlers'

Expand Down Expand Up @@ -82,7 +82,7 @@ function changeState (channel, newState) {
function send (channel, message) {
const { debug = false } = options.get(channel)
if (debug) console.log('Send message: ', message)
websockets.get(channel).send(JSONBig.stringify(message))
websockets.get(channel).send(JsonBig.stringify(message))
}

function enqueueAction (channel, guard, action) {
Expand Down Expand Up @@ -148,7 +148,7 @@ function ping (channel) {
}

function onMessage (channel, data) {
const message = JSONBig.parse(data)
const message = JsonBig.parse(data)
const { debug = false } = options.get(channel)
if (debug) console.log('Receive message: ', message)
if (message.id) {
Expand Down
Loading

0 comments on commit 55645a9

Please sign in to comment.