Some more bugfixing