fix: negation
Some checks failed
Gitea Build Check / Build (pull_request) Failing after 1m8s

This commit is contained in:
SoXX 2024-10-15 10:57:33 +02:00
parent 28c19101be
commit 6a11dc57a4

View File

@ -36,7 +36,7 @@ func CreatePoolPost(ctx context.Context, poolID models.PoolID, postID models.Pos
return models.PoolPost{}, utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.PoolIDIsEmpty})
}
if len(poolID) == 0 {
if len(poolID) != 0 {
return models.PoolPost{}, utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.PoolIDIsWrongLength})
}
@ -92,7 +92,7 @@ func DeletePoolPost(ctx context.Context, poolID models.PoolID, postID models.Pos
return utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.PoolIDIsEmpty})
}
if len(poolID) == 0 {
if len(poolID) != 0 {
return utils.HandleError(ctx, span, localLogger, &otterError.EntityValidationFailed{Reason: otterError.PoolIDIsWrongLength})
}