policy/v2: use value receiver for SSHCheckPeriod.Validate

recvcheck ignores UnmarshalJSON, so the pointer receiver here was the
odd one out against value-receiver MarshalJSON. Validate only reads.
This commit is contained in:
Kristoffer Dalby
2026-08-25 07:20:12 +00:00
committed by Kristoffer Dalby
parent 2c76d5c5b7
commit 77caa94400
+1 -1
View File
@@ -2850,7 +2850,7 @@ func (p SSHCheckPeriod) MarshalJSON() ([]byte, error) {
// Validate rejects negative durations and anything above the inclusive // Validate rejects negative durations and anything above the inclusive
// 168h max. // 168h max.
func (p *SSHCheckPeriod) Validate() error { func (p SSHCheckPeriod) Validate() error {
if p.Always { if p.Always {
return nil return nil
} }