That said, all airlines should have something in their booking system that checks your expiration date against the visa rules for any country you are travelling to and then provide a warning to indicate you need a new passport. It really wouldn’t be that hard to implement.