removed debug line, added error log line