Enforce Email Domain Restriction on Google

How can I achieve this? I tried doing the example from the documentation (https://www.better-auth.com/docs/concepts/hooks#example-enforce-email-domain-restriction) but that did not work for my case. I am trying to restrict for only a specific domain "example.com" to be accepted to sign up.

Thank you!
Better Auth Hooks let you customize BetterAuth's behavior
Was this page helpful?