Skip to content

Commit

Permalink
Fix watcher routes broken by Hapi upgrade (#26713) (#26718)
Browse files Browse the repository at this point in the history
  • Loading branch information
Spencer authored Dec 5, 2018
1 parent 42102ba commit eda9076
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,18 +57,18 @@ export function registerLoadRoute(server) {
};

const watchHistoryItem = WatchHistoryItem.fromUpstreamJson(json);
({
return {
watchHistoryItem: watchHistoryItem.downstreamJson
});
};
})
.catch(err => {
// Case: Error from Elasticsearch JS client
// Case: Error from Elasticsearch JS client
if (isEsError(err)) {
throw wrapEsError(err);
}

// Case: default
wrapUnknownError(err);
throw wrapUnknownError(err);
});
},
config: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ export function registerExecuteRoute(server) {
};

const watchHistoryItem = WatchHistoryItem.fromUpstreamJson(json);
({
return {
watchHistoryItem: watchHistoryItem.downstreamJson
});
};
})
.catch(err => {

Expand All @@ -59,7 +59,7 @@ export function registerExecuteRoute(server) {
}

// Case: default
wrapUnknownError(err);
throw wrapUnknownError(err);
});
},
config: {
Expand Down

0 comments on commit eda9076

Please sign in to comment.