aboutsummaryrefslogtreecommitdiffstats
path: root/entities/identity
diff options
context:
space:
mode:
Diffstat (limited to 'entities/identity')
-rw-r--r--entities/identity/identity_user.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/entities/identity/identity_user.go b/entities/identity/identity_user.go
index cd67459e..435af060 100644
--- a/entities/identity/identity_user.go
+++ b/entities/identity/identity_user.go
@@ -36,7 +36,7 @@ func GetUserIdentity(repo repository.Repo) (*Identity, error) {
func GetUserIdentityId(repo repository.Repo) (entity.Id, error) {
val, err := repo.LocalConfig().ReadString(identityConfigKey)
- if err == repository.ErrNoConfigEntry {
+ if errors.Is(err, repository.ErrNoConfigEntry) {
return entity.UnsetId, ErrNoIdentitySet
}
if err == repository.ErrMultipleConfigEntry {
@@ -58,7 +58,7 @@ func GetUserIdentityId(repo repository.Repo) (entity.Id, error) {
// IsUserIdentitySet say if the user has set his identity
func IsUserIdentitySet(repo repository.Repo) (bool, error) {
_, err := repo.LocalConfig().ReadString(identityConfigKey)
- if err == repository.ErrNoConfigEntry {
+ if errors.Is(err, repository.ErrNoConfigEntry) {
return false, nil
}
if err != nil {