summaryrefslogtreecommitdiff
path: root/p/scripts/main.js
diff options
context:
space:
mode:
authorGravatar Amaury Carrade <amaury@carrade.eu> 2014-01-26 21:39:21 +0100
committerGravatar Amaury Carrade <amaury@carrade.eu> 2014-01-26 21:39:21 +0100
commitd56f51d5fc375ef808433d9f32455dab28d71c84 (patch)
treeccf6e62faa89d59124158077897c1c5bd8ffbd17 /p/scripts/main.js
parent19eefd434c45791ff48c0b5a9ecc642da72b71da (diff)
Style de code
Diffstat (limited to 'p/scripts/main.js')
-rw-r--r--p/scripts/main.js24
1 files changed, 12 insertions, 12 deletions
diff --git a/p/scripts/main.js b/p/scripts/main.js
index ed3cf3779..ddfa0aec8 100644
--- a/p/scripts/main.js
+++ b/p/scripts/main.js
@@ -644,18 +644,18 @@ function init_loginForm() {
alert('Invalid user!');
} else {
try {
- var strong = window.Uint32Array && window.crypto && (typeof window.crypto.getRandomValues === 'function'),
- s = dcodeIO.bcrypt.hashSync($('#passwordPlain').val(), data.salt1),
- c = dcodeIO.bcrypt.hashSync(data.nonce + s, strong ? 4 : poormanSalt());
- $('#challenge').val(c);
- if (s == '' || c == '') {
- alert('Crypto error!');
- } else {
- success = true;
- }
- } catch (e) {
- alert('Crypto exception! ' + e);
- }
+ var strong = window.Uint32Array && window.crypto && (typeof window.crypto.getRandomValues === 'function'),
+ s = dcodeIO.bcrypt.hashSync($('#passwordPlain').val(), data.salt1),
+ c = dcodeIO.bcrypt.hashSync(data.nonce + s, strong ? 4 : poormanSalt());
+ $('#challenge').val(c);
+ if (s == '' || c == '') {
+ alert('Crypto error!');
+ } else {
+ success = true;
+ }
+ } catch (e) {
+ alert('Crypto exception! ' + e);
+ }
}
}).fail(function() {
alert('Communication error!');