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-blockservice
Commits
0d2ac7b7
Commit
0d2ac7b7
authored
Sep 07, 2016
by
Jeromy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SQUASHME: some cleanup
License: MIT Signed-off-by:
Jeromy
<
why@ipfs.io
>
parent
1aafbacd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
9 deletions
+0
-9
blockservice.go
blockservice.go
+0
-9
No files found.
blockservice.go
View file @
0d2ac7b7
...
...
@@ -119,7 +119,6 @@ func (s *BlockService) AddObjects(bs []Object) ([]*cid.Cid, error) {
func
(
s
*
BlockService
)
GetBlock
(
ctx
context
.
Context
,
c
*
cid
.
Cid
)
(
blocks
.
Block
,
error
)
{
log
.
Debugf
(
"BlockService GetBlock: '%s'"
,
c
)
// TODO: blockstore shouldnt care about Cids, need an easier way to strip the abstraction
block
,
err
:=
s
.
Blockstore
.
Get
(
key
.
Key
(
c
.
Hash
()))
if
err
==
nil
{
return
block
,
nil
...
...
@@ -200,11 +199,3 @@ func (s *BlockService) Close() error {
log
.
Debug
(
"blockservice is shutting down..."
)
return
s
.
Exchange
.
Close
()
}
type
RawBlockObject
struct
{
blocks
.
Block
}
func
(
rob
*
RawBlockObject
)
Cid
()
*
cid
.
Cid
{
return
cid
.
NewCidV0
(
rob
.
Block
.
Multihash
())
}
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