Fixed bugs from last commit -.-