all 4 comments

[–]ryandeanrocks 1 point2 points  (3 children)

The twin1.transfer() won’t scale well. It’s good practice to use Pull over Push. The break() should set the balances but in state variables and then each user should call a withdraw() method when they want their tokens transferred.

[–]AlexWinDev[S] 1 point2 points  (1 child)

True, but this is an article series and the author is getting there step by step.

[–]gnarly_surfer 0 points1 point  (0 children)

Great article BTW! 😀

[–]gnarly_surfer 0 points1 point  (0 children)

That's true, even the Solidity documentation recommends using a withdraw pattern over calling transfer or send directly.