trying to fix undefedined issue...