While the error message is ugly (should not 500 the server) the behavior is intentional: we put a referential constraint on there to keep from accidentally deleting a load of data if the user accidentally deletes the domain: you have to disable the domain first, and then delete it for the same reason.
While the error message is ugly (should not 500 the server) the behavior is intentional: we put a referential constraint on there to keep from accidentally deleting a load of data if the user accidentally deletes the domain: you have to disable the domain first, and then delete it for the same reason.