Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don’t memoize root_tenant in validation method
Validation validate_only_one_root was using memoized method Tenant#root_tenant which is called before after_save hook which is creating default group (Tenant#create_tenant_group) and thanks to this fact in variable (@root_tenant) was filled without created default group created in (Tenant#create_tenant_group) and it was causing problems for specs. (then tests were working with instance of root tenant without default group )
- Loading branch information