Skip to content

Commit 7de2424

Browse files
committed
fix: use core.Uuid{} zero values consistently in policy.go
Replace uuid.UUID{} zero-value returns with core.Uuid{} in the Create method error branches to maintain consistent UUID type references throughout the transition to schemas core.Uuid. Signed-off-by: Lee Calcote <lee.calcote@layer5.io>
1 parent e6f8cff commit 7de2424

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

models/meshmodel/core/v1beta1/policy.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,12 @@ func (p *PolicyDefinition) Create(db *database.Handler, hostID core.Uuid) (core.
4949

5050
mid, err := p.Model.Create(db, hostID)
5151
if err != nil {
52-
return uuid.UUID{}, err
52+
return core.Uuid{}, err
5353
}
5454
p.ModelID = mid
5555
err = db.Omit(clause.Associations).Create(&p).Error
5656
if err != nil {
57-
return uuid.UUID{}, err
57+
return core.Uuid{}, err
5858
}
5959
return p.ID, nil
6060
}

0 commit comments

Comments
 (0)