cleanup error logging fix #43