chore: use Ash.ToTenant

This commit is contained in:
Zach Daniel 2024-03-27 16:27:24 -04:00
parent 75ee0ab2cb
commit e3dd3560ea

View file

@ -727,7 +727,7 @@ defmodule AshPostgres.DataLayer do
defp repo_opts(_repo, timeout, tenant, resource) do
if Ash.Resource.Info.multitenancy_strategy(resource) == :context do
[prefix: tenant]
[prefix: Ash.ToTenant.to_tenant(resource, tenant)]
else
if schema = AshPostgres.DataLayer.Info.schema(resource) do
[prefix: schema]