From 38deca6a2caf773e05b990700bd24dd81a0c9c88 Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Tue, 3 Sep 2019 16:30:00 +0200 Subject: [PATCH] unset arg is bool:false & spell corection add improvements and sugestions of gary-kim Co-Authored-By: Gary Kim --- sortt.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/sortt.js b/sortt.js index 3fad9fa..2b161e7 100644 --- a/sortt.js +++ b/sortt.js @@ -8,17 +8,15 @@ */ -//creat global function with main routine +//create global function with main routine window.sortt=function(normsort,revsort,isdefault){ //sortTable [normsort] (revsort) (isdefault) //normsort is needet - if (typeof normsort === 'undefined') return false; + if (normsort) return false; //default values of optinal parameters - if (typeof revsort === 'undefined') revsort = ""; - if (typeof isdefault === 'undefined') isdefault = false; - if (!(typeof isdefault === 'boolean')) isdefault = false; + if (revsort) revsort = ""; // parse URL /* script check if url has already a sort=