modified error output
deleted some print out in writing log