Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
interface-go-dms3-core
Commits
a288d2c9
Commit
a288d2c9
authored
Aug 28, 2018
by
Łukasz Magiera
Committed by
Steven Allen
Sep 10, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
coreapi: dht: remove option prefix
License: MIT Signed-off-by:
Łukasz Magiera
<
magik6k@gmail.com
>
parent
03a210bb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
options/dht.go
options/dht.go
+4
-4
No files found.
options/dht.go
View file @
a288d2c9
...
...
@@ -43,18 +43,18 @@ type dhtOpts struct{}
var
Dht
dhtOpts
//
With
Recursive is an option for Dht.Provide which specifies whether to provide
// Recursive is an option for Dht.Provide which specifies whether to provide
// the given path recursively
func
(
dhtOpts
)
With
Recursive
(
recursive
bool
)
DhtProvideOption
{
func
(
dhtOpts
)
Recursive
(
recursive
bool
)
DhtProvideOption
{
return
func
(
settings
*
DhtProvideSettings
)
error
{
settings
.
Recursive
=
recursive
return
nil
}
}
//
With
NumProviders is an option for Dht.FindProviders which specifies the
// NumProviders is an option for Dht.FindProviders which specifies the
// number of peers to look for. Default is 20
func
(
dhtOpts
)
With
NumProviders
(
numProviders
int
)
DhtFindProvidersOption
{
func
(
dhtOpts
)
NumProviders
(
numProviders
int
)
DhtFindProvidersOption
{
return
func
(
settings
*
DhtFindProvidersSettings
)
error
{
settings
.
NumProviders
=
numProviders
return
nil
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment