1.3.3 fix captcha

I have found the reason why captcha sometimes didnt work - some async mixup where the empty result was used instead of a callback. I ended up rewriting the hasCaptchas-Loop. Also, I allowed myself some code style touchup (i.e. fixed up indentation and some minor JS-Traps).

I have not found the corresponding code in 2.x-Master for pyload 0.5 so I guess this is the right one then.