I’m trying to understand DDP protocol that meteor uses
I use Meteor Methods to send data from client to server, and I have many methods
I wish to know if there is a way to have in the main.js of server some sort of function that display the transmitted data before it arrives to server Method
for example
Client calls a method ( any method from anywhere ) → I catch the data before it arrives to server Meteor Method and apply some kind of work on it like sanitizing the data entered to prevent XSS → data continues to Method Method
This way i will have one place to receive every argument sent from any method and I will sanitize it and and the data just continues to find its way to that specific method in a cleaner form
I could do this per method and do all the work on the arguments per method but i thought one place for such work like sanitizing the data would be better