Allow removing global exposure linked firewalls
Closed this issue · 1 comments
Floriferous commented
We've found global exposure to be extremely useful for our admin apps that can access all the data. It gives all the power to the front-end to query whatever it wants, while also knowing in this part of our app that there will be no abuse, so we don't have to restrict anything in the global exposure either.
It'd be useful for global exposures to be able to skip the linked firewalls. Especially when performing large nested queries, as the firewalls are called a lot, and I'm hoping to improve global query performance with this change.
Floriferous commented
The solution is this:
Collection.expose({
firewall(filters, options, userId) {},
publication: true,
method: true,
blocking: false,
body: () => true, // This lets you ignore all nested firewalls
});