Debug the changes, seems to work. Closing issue #9 will probably never happen, as it will probably be an ongoing enhancement, but at least it seems a little smarter now. Also, the code desperately needs cleaned and refactored, so that's probably the next goal - I'll open a new issue for it, sooner or later.