Fix code to pass test