summaryrefslogtreecommitdiff
path: root/src/srp_account.js
diff options
context:
space:
mode:
authorAzul <azul@riseup.net>2013-06-22 16:17:45 +0200
committerAzul <azul@riseup.net>2013-06-22 16:17:45 +0200
commit21c3134a868efa4104bb87a2a8fc36f485e163bb (patch)
tree14a591408caecc369b84d985dae1864019f3aedc /src/srp_account.js
parent16602079b3cd92ad85f3d4afe57763c029b67ae8 (diff)
refactor: separate account from sessionrefactor/separate-session
Diffstat (limited to 'src/srp_account.js')
-rw-r--r--src/srp_account.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/srp_account.js b/src/srp_account.js
new file mode 100644
index 0000000..336e013
--- /dev/null
+++ b/src/srp_account.js
@@ -0,0 +1,13 @@
+srp.Account = function(login, password) {
+
+ // Returns the user's identity
+ this.login = function() {
+ return login || document.getElementById("srp_username").value;
+ };
+
+ // Returns the password currently typed in
+ this.password = function() {
+ return password || document.getElementById("srp_password").value;
+ };
+
+}