Skip to content

Commit

Permalink
coreapi pubsub: fix review nits
Browse files Browse the repository at this point in the history
License: MIT
Signed-off-by: Łukasz Magiera <[email protected]>
  • Loading branch information
magik6k committed Sep 26, 2018
1 parent a232340 commit 1facb7b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 3 additions & 0 deletions core/commands/pubsub.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@ This command outputs data in the following encodings:
discover, _ := req.Options["discover"].(bool)

sub, err := api.PubSub().Subscribe(req.Context, topic, options.PubSub.Discover(discover))
if err != nil {
return err
}
defer sub.Close()

if f, ok := res.(http.Flusher); ok {
Expand Down
1 change: 0 additions & 1 deletion core/coreapi/interface/pubsub.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ type PubSubAPI interface {
Ls(context.Context) ([]string, error)

// Peers list peers we are currently pubsubbing with
// TODO: WithTopic
Peers(context.Context, ...options.PubSubPeersOption) ([]peer.ID, error)

// Publish a message to a given pubsub topic
Expand Down

0 comments on commit 1facb7b

Please sign in to comment.