Skip to content

Commit

Permalink
For a single item, it's probably a better approach to use "Observable…
Browse files Browse the repository at this point in the history
….just".
  • Loading branch information
edisonh committed Jan 28, 2016
1 parent 0d79d03 commit e205888
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ public void processEvent(Event event) {
return;
}

val buildEvent = objectMapper.convertValue(event, BuildEvent.class);
Observable.from(Collections.singletonList(buildEvent))
BuildEvent buildEvent = objectMapper.convertValue(event, BuildEvent.class);
Observable.just(buildEvent)
.doOnNext(this::onEchoResponse)
.subscribe(triggerEachMatchFrom(pipelineCache.getPipelines()));
}
Expand Down

0 comments on commit e205888

Please sign in to comment.