Exactly.
I know some say that this is strawman's argument, because the options are not leave or stay indefinitely, but in practical terms I don't think there's another option here.
If we would've extended our overstay at our discretion, the Taliban would most likely retaliate and in midst of ongoing conflict it is kinda never a good time to retreat.