While trying to use functions in the config file, the req object was not being passed in. It seems this was being caused by the .call usage in the server middleware. I have instead removed it to call the function directly which seemed to have fixed the issue.
While trying to use functions in the config file, the req object was not being passed in. It seems this was being caused by the
.call
usage in the server middleware. I have instead removed it to call the function directly which seemed to have fixed the issue.