adding logging statements