From bfcafcd800b1fa48702625014594c196783cdac9 Mon Sep 17 00:00:00 2001 From: Fergal Moran Date: Tue, 25 Jun 2013 21:33:36 +0100 Subject: [PATCH] Fixed incessant nagging --- static/js/app/lib/utils.coffee | 2 +- static/js/app/lib/utils.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/static/js/app/lib/utils.coffee b/static/js/app/lib/utils.coffee index ded7555..af6464d 100755 --- a/static/js/app/lib/utils.coffee +++ b/static/js/app/lib/utils.coffee @@ -17,7 +17,7 @@ define ['jquery', 'bootstrap', 'toastr'], ($, bootstrap, toastr) -> if document.cookie.indexOf("sessionId") $.getJSON "/ajax/session_play_count", (data) => console.log "utils: got playcount" - if data.play_count != 0 and (data.play_count % com.podnoms.settings.nag_count) + if data.play_count != 0 and ((data.play_count % com.podnoms.settings.nag_count) == 0) @modal "dlg/PlayCountLoginAlert" true diff --git a/static/js/app/lib/utils.js b/static/js/app/lib/utils.js index aeb25ca..c05ff3f 100755 --- a/static/js/app/lib/utils.js +++ b/static/js/app/lib/utils.js @@ -27,7 +27,7 @@ if (document.cookie.indexOf("sessionId")) { $.getJSON("/ajax/session_play_count", function(data) { console.log("utils: got playcount"); - if (data.play_count !== 0 && (data.play_count % com.podnoms.settings.nag_count)) { + if (data.play_count !== 0 && ((data.play_count % com.podnoms.settings.nag_count) === 0)) { return _this.modal("dlg/PlayCountLoginAlert"); } });