diff --git a/pkg/database/pool_reference.go b/pkg/database/pool_reference.go index e675a07..fed3315 100644 --- a/pkg/database/pool_reference.go +++ b/pkg/database/pool_reference.go @@ -40,7 +40,7 @@ func CreatePoolReference(ctx context.Context, poolID models.PoolID, sourceID mod return models.PoolReference{}, utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.PoolIDIsWrongLength}) } - if sourceID == "" { + if len(sourceID) == 0 { return models.PoolReference{}, utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.SourceIDIsEmpty}) } @@ -100,7 +100,7 @@ func DeletePoolReference(ctx context.Context, poolID models.PoolID, sourceID mod return utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.PostIDIsWrongLength}) } - if sourceID == "" { + if len(sourceID) == 0 { return utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.SourceIDIsEmpty}) }