BA
Better Auth•4d ago
Platon

Anyway to set a non-user input field based on request headers?

I have a database field that needs to be setup on signup, based on request headers. Because this value is handled server side, I've set input to false on this additional field - now I've done that, however, the value from the before hook is entirely ignored. I can set the field to input: true however that makes it settable client side, which of course can be overriten, it just doesn't seem as clean Any ideas?
2 Replies
Platon
PlatonOP•4d ago
Additionally, setting input: false and adding a defaultValue will ignore the defaultValue I feel like whatever my settings are for the input, if I set something in my before hook, that should take priority
Ping
Ping•13h ago
Thst shouldn't be the case 🤔 Can I see your auth config?

Did you find this page helpful?