Properly check for a pre-existing error in `User#namespace_uniq`
Rails adds an empty error to the Errors object even if you just call
`#[]` on it:
```
[1] pry(main)> u = User.last
[2] pry(main)> u.errors.keys
=> []
[3] pry(main)> u.errors[:username].present?
=> false
[4] pry(main)> u.errors.keys
=> [:username]
```
Showing
Please
register
or
sign in
to comment