You should not have had to go back to the US for your visa. Sometimes they can't do it in Bangkok, but there's usually an embassy much closer than that where they can.
The thing with them is that I don't think they deny enough people to get in any trouble for that, but since the latest terrorist issues the immigration department was put under a lot of scrutiny and it seems like they are just going for these harsh enforcement to give everyone the idea that they are much stricter now and protecting the country.