A bunch of fixes ;)