improving logging