Page 1 of 1

XH 1.6.7: little bug in admin.js

Posted: Sat Jul 04, 2015 9:57 am
by Holger
There's a little bug in admin.js:

Code: Select all

TypeError: inputs[0] is undefined
(admin.js line 530)

Code: Select all

function undoPasswordAutocompletion() {
        var inputs = document.getElementsByName(
            "PL3bbeec384_security_password_OLD"
        );
        if (inputs) {
            inputs[0].value = "";
        }
    }
IMO a fix would be to change if(inputs) to if(inputs[0])

Re: XH 1.6.7: little bug in admin.js

Posted: Sat Jul 04, 2015 10:52 am
by cmb
Holger wrote:There's a little bug in admin.js:
Indeed, but I've already fixed it, see http://sourceforge.net/p/cmsimplexh/bugs/22/. Your fix is more efficient, though; feel free to change. :)