Fixed all the errors in createAccount