Added logging checks