Fix odd bugs