Fixed code, I hope