Added error message to log statement