fixed errors in code
more changes