Added logging statements