simplify the check_req function