a little refactoring, featuring:
NEW BUGS! :D