diff options
author | Devaev Maxim <[email protected]> | 2021-02-07 23:26:50 +0300 |
---|---|---|
committer | Devaev Maxim <[email protected]> | 2021-02-07 23:26:50 +0300 |
commit | 711816bd2665b450a63d90744740bb4cc0df4efe (patch) | |
tree | ff3da6538bf7fdf8e6cc78f794b825c1db000adb /web/share/js/kvm/hid.js | |
parent | 365d8e9fefd454933e536a76f2c28e8ec6056625 (diff) |
refactoring
Diffstat (limited to 'web/share/js/kvm/hid.js')
-rw-r--r-- | web/share/js/kvm/hid.js | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/web/share/js/kvm/hid.js b/web/share/js/kvm/hid.js index efbb46c0..bcd1e479 100644 --- a/web/share/js/kvm/hid.js +++ b/web/share/js/kvm/hid.js @@ -196,9 +196,7 @@ export function Hid() { var __clickPasteAsKeysButton = function() { let text = $("hid-pak-text").value.replace(/[^\x00-\x7F]/g, ""); // eslint-disable-line no-control-regex if (text) { - let confirm_msg = text.length !== 1 ? - `You're going to paste ${text.length} characters.<br>` : - `You're going to paste ${text.length} character.<br>`; + let confirm_msg = `You're going to paste ${text.length} character${text.length ? "s" : ""}.<br>`; confirm_msg += "Are you sure you want to continue?"; wm.confirm(confirm_msg).then(function(ok) { |