I'm a little confused as to which point in time you are talking about, so I'll just go through all the times I think you could be referencing.
If you are talking about the time when McGregor was champion and went on his couple year hiatus, there was no talk of them fighting because McGregor was focused on other things and the UFC was focused on trying to crown someone else as undisputed champion to move on from him (and try to entice him back).
If you are talking about after Khabib ended up being crowned champion, then there was no real point to put that fight on cause the fight to make was (current champion) Khabib vs. (uncrowned, lineal champion) McGregor. Also, one of the major reasons Conor came back was because of the "bad blood" between him and Khabib.
After that, McGregor went on another mini-hiatus and, by the time he came back, both Tony and Khabib had won their fights and their UFC 249 meeting was being negotiated. So, McGregor had to take another fight.
Now, if you're talking about McGregor replacing Khabib for the UFC 249 main event, then it's because (ironically) McGregor was doing the same thing in Ireland that Khabib was doing in Russia.
IDK if that answers your question.