fixed the codes