Skip to content

Commit

Permalink
chore: Report which module is at fault, when raising an error about r…
Browse files Browse the repository at this point in the history
…elationship domain inclusion (#1384)
  • Loading branch information
sevenseacat authored Aug 12, 2024
1 parent 5b40040 commit 074b65e
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ defmodule Ash.Domain.Verifiers.ValidateRelatedResourceInclusion do
)

raise """
Resource `#{inspect(relationship.destination)}` #{message} for autogenerated join relationship: `:#{relationship.name}`
Error when compiling `#{inspect(relationship.source)}`: Resource `#{inspect(relationship.destination)}` #{message} for autogenerated join relationship: `:#{relationship.name}`
Relationship was generated by the `many_to_many` relationship `#{inspect(parent_relationship.name)}`
Expand All @@ -75,7 +75,7 @@ defmodule Ash.Domain.Verifiers.ValidateRelatedResourceInclusion do
"""
else
raise """
Resource `#{inspect(relationship.destination)}` in relationship `:#{relationship.name}` #{message}. Please do one of the following
Error when compiling `#{inspect(relationship.source)}`: Resource `#{inspect(relationship.destination)}` in relationship `:#{relationship.name}` #{message}. Please do one of the following
1. add the resource to the domain `#{inspect(domain)}`
2. configure a different domain
Expand Down

0 comments on commit 074b65e

Please sign in to comment.