The situation described in the OP is pretty narrowly defined.
I don’t think the kids in question were in any danger, and at least responsible adults on one end were aware of it. But, one touchy point is the extent to which they could accurately predict the response of the parents on the other side. What will they say when they find their kid home, and learn how she got there? When you assume responsibility over other peoples’ kids, such as at a sleepover, you have to be careful about behaving in ways they will be uncomfortable with. They may not agree that curfew is “a bullshit law.” And they may not wish you to be making the decision as to which laws are or are not bullshit.
IMO&E, it is generally better to be more careful, protective, responsible, and law-abiding when it comes to other peoples’ kids, than you may need to be with your own. I think the parents should have walked/driven the kid home.
Also, speaking in very broad generalities, I think that the reasonableness exhibited by teens in their decision-making somewhat lessens as the hour gets late - and may be further degraded when they are in groups and unfamiliar places - such as out and about in the middle of the night. As a parent, I don’t think you need to be in a hurry to put them in that kind of situation at too early of an age.