One of the jobs of the blockchain is to ensure that two conflicting transactions cannot both be confirmed. It is possible that different nodes in the network will temporarily have different opinions about which of the two conflicting transactions took place, but this will quickly be cleared up once consensus is reached via the chain.