corrected code error