1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-26 19:47:20 +00:00

Fix for running under node-webkit

This commit is contained in:
Jermolene 2014-05-28 08:57:29 +01:00
parent d8a142fed5
commit 62c602e9d2

View File

@ -565,7 +565,7 @@ Crypto helper object for encrypted content. It maintains the password text in a
the password, and to encrypt/decrypt a block of text
*/
$tw.utils.Crypto = function() {
var sjcl = $tw.browser ? window.sjcl : require("./sjcl.js"),
var sjcl = $tw.node ? require("./sjcl.js") : window.sjcl,
currentPassword = null,
callSjcl = function(method,inputText,password) {
password = password || currentPassword;