I have no idea what happened here, didn't write this (Oskar)
Last commit again with minor change