Skip to content

Commit

Permalink
Review requests
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelomorgado committed Mar 27, 2019
1 parent e078c4b commit d452ac7
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -192,11 +192,14 @@ const createParcel = async parcel => {
});

action.on("error", message => {
const { error } = message;
console.log(error);
action.unsubscribe();
reject();
});

setTimeout(() => {
console.log(`Timeout reached`);
action.unsubscribe();
reject();
}, EVENTS_TIMEOUT);
Expand Down Expand Up @@ -244,18 +247,23 @@ const createEstate = async estate => {
action.on("confirmation", () => {});

action.on("error", message => {
const { error } = message;
console.log(error);
estateContract.unsubscribe();
action.unsubscribe();
reject();
});

estateContract.on("error", message => {
const { error } = message;
console.log(error);
estateContract.unsubscribe();
action.unsubscribe();
reject();
});

setTimeout(() => {
console.log(`Timeout reached`);
estateContract.unsubscribe();
action.unsubscribe();
reject();
Expand Down

0 comments on commit d452ac7

Please sign in to comment.