Skip to content

Commit

Permalink
Use triple equality
Browse files Browse the repository at this point in the history
This is a little safer for javascript equality.
  • Loading branch information
matthewbauer committed Nov 8, 2019
1 parent 99514af commit 50950b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jsaddle-warp/src/Language/Javascript/JSaddle/WebSockets.hs
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ jsaddleJs = jsaddleJs' Nothing
-- sed -e 's|\\|\\\\|g' -e 's|^| \\|' -e 's|$|\\n\\|' -e 's|"|\\"|g' data/jsaddle.js | pbcopy
jsaddleJs' :: Maybe ByteString -> Bool -> ByteString
jsaddleJs' jsaddleUri refreshOnLoad = "\
\if(typeof global !== \"undefined\" && typeof require == \"function\") {\n\
\if(typeof global !== \"undefined\" && typeof require === \"function\") {\n\
\ global.window = global;\n\
\ global.WebSocket = require('ws');\n\
\}\n\
Expand Down

0 comments on commit 50950b5

Please sign in to comment.