Skip to content

Commit 2011532

Browse files
authored
Merge pull request #56 from jungaretti/fix-priority-comparison
Fix priority comparison
2 parents 9be2b61 + 6b56e09 commit 2011532

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

pkg/config/record.go

+4
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ func (r Record) GetData() string {
3030
}
3131

3232
func (r Record) GetPriority() string {
33+
if r.Priority == 0 {
34+
return ""
35+
}
36+
3337
return fmt.Sprint(r.Priority)
3438
}
3539

pkg/providers/porkbun/record/record.go

+4
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ func (r Record) GetData() string {
2929
}
3030

3131
func (r Record) GetPriority() string {
32+
if r.Priority == "0" {
33+
return ""
34+
}
35+
3236
return r.Priority
3337
}
3438

0 commit comments

Comments
 (0)