Fix bugs in `has_id?` and `has_class?` methods. Refactor unreadable code.
Fix bug with parsing non html text