Skip to content

Commit

Permalink
Fix Kube backed leasetime code:
Browse files Browse the repository at this point in the history
It was safecast parsing the wrong value.

Signed-off-by: Jacob Weinstock <[email protected]>
  • Loading branch information
jacobweinstock committed Oct 14, 2024
1 parent 9b12f94 commit 206ef93
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/backend/kube/kube.go
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ func toDHCPData(h *v1alpha1.DHCP) (*data.DHCP, error) {
// lease time required
// Default to one week
d.LeaseTime = 604800
if v, err := safecast.ToUint32(d.LeaseTime); err == nil {
if v, err := safecast.ToUint32(h.LeaseTime); err == nil {
d.LeaseTime = v
}

Expand Down

0 comments on commit 206ef93

Please sign in to comment.