Meteor Server Request URL

Is there any way to find out from which URL the request is requested on the Meteor server?

In particular, I would like to filter the Meteor.publish method based on the URL parameters that the request has. Doing this on the server would be safer than sending parameters from the client to Meteor.subscribe , as client vars can be hacked.

+4
source share
1 answer

It just turned out that at least inside the Meteor.publish function Meteor.publish you can find the request URL from this.session.socket.headers .

+1
source

Source: https://habr.com/ru/post/1445748/


All Articles