There is one other small change we're going to make to our expiration complete listener right now.
Whenever we receive a message we're going to find a corresponding order no matter what.
And always mark the order has been cancelled.
As you can imagine there might be a kind of big downside to this.
What would happen if we received a cancellation event around an order that has already been paid for.
Well chances are we would take this order that has already been paid for already marked as complete
and cancel it anyways so we do have to add in a little check here and just make sure that we do not
try to cancel an order that has been paid for right after our little check to make sure that we have
an order.
We're gonna take a look at the order status property and we're going to say that if this is equal to
order status not complete then let's just return early act the message because we do not want to do
anything with this cancellation event.
So I'm going to return early and call message dot back like so ok good little fix because right here
and continue in just a minute.