What you're talking about is the concurrency "issue". It was a bad designed app.To code Smart Contract on Cardano you have to learn the "Cardano way" of building Smart Contracts. It's like multi-core systems : you have to learn how to take advantages of the several cores.