_sendMessage should use _reject()
sjmcdowall opened this issue · 2 comments
sjmcdowall commented
https://github.com/flywheelsports/hydra/blob/master/index.js#L1364
According to the "specs" for the function, on error(s) the method should call a reject .. but in all instances it actually invokes resolve() with an error message. Besides breaking the contract -- it probably should throw a reject() on errors.
Suspicious lines:
https://github.com/flywheelsports/hydra/blob/master/index.js#L1382
https://github.com/flywheelsports/hydra/blob/master/index.js#L1396
cjus commented
@sjmcdowall the code does what we want. However, the JSDOC should be updated to reflect the usage.
sjmcdowall commented
This was fixed in PR#182 ...