Both transactions will probably confirm at the same time, so essentially they were simultaneous. And bitcoin supports transactions that build on each other so they have no problem to confirm. I can sign a transaction and "fund" it a few minutes later. They are both unconfirmed anyway until they can both confirm.