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
go-dms3
Commits
1f9541d2
Commit
1f9541d2
authored
Oct 28, 2014
by
Brian Tiger Chow
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactor(blockservice) export blockservice.ErrNotFound
parent
cee1e9cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
blockservice/blockservice.go
blockservice/blockservice.go
+3
-1
No files found.
blockservice/blockservice.go
View file @
1f9541d2
package
blockservice
import
(
"errors"
"fmt"
context
"github.com/jbenet/go-ipfs/Godeps/_workspace/src/code.google.com/p/go.net/context"
...
...
@@ -13,6 +14,7 @@ import (
)
var
log
=
u
.
Logger
(
"blockservice"
)
var
ErrNotFound
=
errors
.
New
(
"blockservice: key not found"
)
// BlockService is a block datastore.
// It uses an internal `datastore.Datastore` instance to store values.
...
...
@@ -73,7 +75,7 @@ func (s *BlockService) GetBlock(ctx context.Context, k u.Key) (*blocks.Block, er
return
blk
,
nil
}
else
{
log
.
Debug
(
"Blockservice GetBlock: Not found."
)
return
nil
,
u
.
ErrNotFound
return
nil
,
ErrNotFound
}
}
...
...
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