Hello,
We've discovered another difference from Realm regarding the context.user data.
When a scheduled trigger invokes a function with system privileges:
For Realm: context.user.type is "system".
For Flowerbase context.user is an empty object.
As a result, this condition worked in Realm for scheduled triggers
if (context.user && context.user.type !== "system" && !context.user.custom_data) { ... }
In flowerbase this leads to an error because there is a context.user but no context.user.custom_data.
That's not a big deal, just a minor discrepancy
Hello,
We've discovered another difference from Realm regarding the context.user data.
When a scheduled trigger invokes a function with system privileges:
For Realm: context.user.type is "system".
For Flowerbase context.user is an empty object.
As a result, this condition worked in Realm for scheduled triggers
if (context.user && context.user.type !== "system" && !context.user.custom_data) { ... }In flowerbase this leads to an error because there is a context.user but no context.user.custom_data.
That's not a big deal, just a minor discrepancy