ICU-738/Refactor internal/db to domain errors (#815)
* Refactor internal/db to domain errors
This commit is contained in:
1 parent
b5d84495a3
commit
bfbb179741
82 files changed
+742
-640
No files matched your search
@@ -104,7 +104,7 @@ func (r *Repository) LookupAuthMethod(ctx context.Context, publicId string, opt
|
||||
a := allocAuthMethod()
|
||||
a.PublicId = publicId
|
||||
if err := r.reader.LookupByPublicId(ctx, &a); err != nil {
|
||||
if errors.Is(err, errors.ErrRecordNotFound) {
|
||||
if errors.IsNotFoundError(err) {
|
||||
return nil, nil
|
||||
}
|
||||
return nil, fmt.Errorf("lookup: password auth method: failed %w for %s", err, publicId)
|
||||
|
||||
Reference in new issue
Block a user