That actually illustrates something about online services. Often (if not most of the time) companies develop them without considering at all that they must still be able to abide by the national laws of each and every country their users/customers reside in... and that's hard. So when something happens the simple option is to geoblock the country.
Isn't that the obvious thing to do
That isn’t necessarily the case though. The only countries they MUST consider are ones with civil judgement treaties like the Lugano agreement that applies here. They don’t have to care about laws in Iran or Russia unless they have entities or assets there.