checking req function