1 00:00:01,350 --> 00:00:01,650 All right. 2 00:00:01,680 --> 00:00:07,470 Let's make sure that as soon as time left goes to zero or below, we display some simple text that says, 3 00:00:07,470 --> 00:00:09,000 sorry, but this order has expired. 4 00:00:09,870 --> 00:00:12,530 Now, the first thing on to do here, you'll notice that we had defaulted. 5 00:00:12,570 --> 00:00:15,630 You state right here or time left, piece of state to empty string. 6 00:00:15,990 --> 00:00:17,160 That doesn't make a lot of sense. 7 00:00:17,220 --> 00:00:17,900 Let's have it. 8 00:00:18,510 --> 00:00:21,510 Or give that thing a default value of just zero instead. 9 00:00:23,410 --> 00:00:26,620 So now after it use effect, I'm going to add in a little check. 10 00:00:26,770 --> 00:00:29,840 I got to say, if time left is less than zero. 11 00:00:31,070 --> 00:00:32,150 Then let's return a div. 12 00:00:34,040 --> 00:00:35,870 That says order expired. 13 00:00:38,650 --> 00:00:41,260 Let's save look back over order expired. 14 00:00:41,860 --> 00:00:43,960 Naturally, let's make sure that's not being displayed all the time. 15 00:00:43,990 --> 00:00:45,670 So I'm gonna create yet another order. 16 00:00:47,080 --> 00:00:47,850 So there's the timer. 17 00:00:47,880 --> 00:00:53,070 And now as soon as it goes into the negatives, it should update and say order expired instead, just 18 00:00:53,070 --> 00:00:55,020 make sure this thing works in a positive right here. 19 00:00:55,050 --> 00:00:59,070 I got to let my timer count down and then come back in just a moment and we'll just make sure that, 20 00:00:59,070 --> 00:01:00,840 yes, this thing does update appropriately.