Verify if res is not undefined
Attach url field to reqOptions instead