fixed the code