What I mean is in one case your code is procedural and communicate with another machine through an API, in case of error you can just bail out as it's part of your API, and in the other your code is event-driven and communicate with a user through a GUI, errors have to result into a working UI, even if that UI is just presenting an error message.