Adding logs to determine error