Skip to content

Commit

Permalink
Update convert.go
Browse files Browse the repository at this point in the history
  • Loading branch information
RichardLindhout authored Feb 8, 2025
1 parent b7cb794 commit 7b896f1
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion boilergql/convert.go
Original file line number Diff line number Diff line change
Expand Up @@ -692,14 +692,22 @@ func Int64ToInt(v int64) int {
return int(v)
}

func NullDotUintToPointerString(v null.Uint) *string {
func NullDotUintToPointerString(v null.Uint64) *string {
if !v.Valid {
return nil
}
u := UintToString(v.Uint)
return &u
}

func NullDotUint64ToPointerString(v null.Uint64) *string {
if !v.Valid {
return nil
}
u := Uint64ToString(v.Uint)
return &u
}

func UintToString(v uint) string {
u := strconv.FormatUint(uint64(v), 10)
return u
Expand Down

0 comments on commit 7b896f1

Please sign in to comment.