fixing debug problem