Skip to content

Commit

Permalink
if the DisableValues is passed then set the validator internally to nil
Browse files Browse the repository at this point in the history
  • Loading branch information
aschmahmann committed Apr 22, 2020
1 parent fc718e1 commit 57ffb53
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions dht_options.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ func (c *config) applyFallbacks(h host.Host) error {
return fmt.Errorf("the default validator was changed without being marked as changed")
}
}

if !c.enableValues {
c.validator = nil
}
return nil
}

Expand Down

0 comments on commit 57ffb53

Please sign in to comment.