From 837bdd80c9c8b2b8b033fc0fa6b7950245f809f3 Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Tue, 11 Jul 2017 16:40:36 -0600 Subject: [PATCH] fixing js --- js/script.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/js/script.js b/js/script.js index ab84331..d609437 100644 --- a/js/script.js +++ b/js/script.js @@ -90,11 +90,7 @@ $('body').on('keyup keypress', '.js-authn-otp-code', function (e) { // if($(this).val().length === $(this).attr("maxlength")){ // $('.submit-btn').prop("disabled", false); // } - if ($(this).val().length === 14) { - $('.submit-btn').prop('disabled', false); - } else { - $('.submit-btn').prop('disabled', true); - } + $(this).val().length === 14 ? $('.submit-btn').prop('disabled', false) : $('.submit-btn').prop('disabled', true); }); $('.js-authn-otp-code').mask('####-####-####');