Bugfixes + updated jshintrc and code