Minor JavaScript

pull/664/head
Alexandre Alapetite 10 years ago
parent 099f5ab760
commit 6e6d7b3c87
  1. 2
      p/scripts/main.js
  2. 2
      p/scripts/shortcut.js

@ -33,7 +33,7 @@ function needsScroll($elem) {
}
function str2int(str) {
if (str == '' || str === undefined) {
if (!str) {
return 0;
}
return parseInt(str.replace(/\D/g, ''), 10) || 0;

@ -43,7 +43,7 @@ shortcut = {
//Find Which key is pressed
if (e.keyCode) code = e.keyCode;
else if (e.which) code = e.which;
if( code == 32 || (code >= 48 && code <= 90) || (code >= 96 && code <= 111) || (code >= 186 && code <= 192) || (code >= 219 && code <= 222)) {
if (code == 32 || (code >= 48 && code <= 90) || (code >= 96 && code <= 111) || (code >= 186 && code <= 192) || (code >= 219 && code <= 222)) { //FreshRSS
var character = String.fromCharCode(code).toLowerCase();
}

Loading…
Cancel
Save