Fixed errors (hopefully)