Pure UI
Now, it would be interesting to see how function pay() should be written with the new approach and how it evolves when the new states ("network went away error", "must be logged in", "certain role", "pre-existing data") are discovered.