Fixing all the previous errors