This decision has a bunch of people lit up. If the whole story were as simple as it is in these forums then they would be rightly so. 
However, it isn't so simple as it seems. In short it is fairly complicated because a lot of people besides Bergdahl screwed up. Top to bottom.
Listen to this fascinating body of investigative reporting if you would like to know a lot more of what and how it happened:
https://serialpodcast.org/season-two
It will only cost you a bit of time to get through it. I think you will find it interesting at the least.