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
p2p
go-p2p-kad-dht
Commits
3a13ac75
Unverified
Commit
3a13ac75
authored
Jan 20, 2018
by
Steven Allen
Committed by
GitHub
Jan 20, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #112 from dirkmc/fix/validation-record
Just pass the record object to validation functions
parents
d2378be3
ed147fe8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
dht_test.go
dht_test.go
+2
-2
package.json
package.json
+2
-2
No files found.
dht_test.go
View file @
3a13ac75
...
...
@@ -50,7 +50,7 @@ func setupDHT(ctx context.Context, t *testing.T, client bool) *IpfsDHT {
}
d
.
Validator
[
"v"
]
=
&
record
.
ValidChecker
{
Func
:
func
(
string
,
[]
byte
)
error
{
Func
:
func
(
*
record
.
ValidationRecord
)
error
{
return
nil
},
Sign
:
false
,
...
...
@@ -150,7 +150,7 @@ func TestValueGetSet(t *testing.T) {
defer
dhtB
.
host
.
Close
()
vf
:=
&
record
.
ValidChecker
{
Func
:
func
(
string
,
[]
byte
)
error
{
return
nil
},
Func
:
func
(
*
record
.
ValidationRecord
)
error
{
return
nil
},
Sign
:
false
,
}
nulsel
:=
func
(
_
string
,
bs
[][]
byte
)
(
int
,
error
)
{
return
0
,
nil
}
...
...
package.json
View file @
3a13ac75
...
...
@@ -84,9 +84,9 @@
},
{
"author"
:
"whyrusleeping"
,
"hash"
:
"Qm
WGtsyPYEoiqTtWLpeUA2jpW4YSZgarKDD2zivYAFz7sR
"
,
"hash"
:
"Qm
ajyQvG3Her6XmwoTHSVUyuEAc9v6AEj2GW3dx4Wyxd5K
"
,
"name"
:
"go-libp2p-record"
,
"version"
:
"
2.1.6
"
"version"
:
"
3.0.0
"
},
{
"author"
:
"whyrusleeping"
,
...
...
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