tweaked some small things after code check