Closed tmulkern closed 6 years ago
Changed usages of push on this._buffered_msg_queue and this._msg_queue to use unshift
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/unshift, removing the need to reverse the array to pop elements in fifo order
Signed-off-by: Tadhg Mulkerntadhg.j.mulkern@gmail.com
@jpwsutton Is this ok to merge?
Thanks for the PR @tmulkern, sorry it took a while to merge in! Nice spot!
Changed usages of push on this._buffered_msg_queue and this._msg_queue to use unshift
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/unshift, removing the need to reverse the array to pop elements in fifo order
Signed-off-by: Tadhg Mulkerntadhg.j.mulkern@gmail.com