Everyone has covered all the pertinent points, except one: fear. Not only can a single flamethrower clear out a bunker effectively, the lone flamethrower cause the abandonment of nearby bunkers as well.
One thing that has not been mentioned about the flamethrower in its bunker-clearing ability is that, in close quarters, i.e. a bunker, the liquid fuel has the tendency to turn into an aerosol. When it does this, the fireball expands DRASTICALLY. You may have seen WWII/Korean War/Vietnam War footage of bunkers that will be hit with a flamethrower, and they will virtually explode in every direction, this is the reason.
When you combine this effect with the primal fear of burning alive, you get a devastating psychological weapon. Humans evolved alongside fire for millions of years. It's deeply engrained in our psyche. We have all been burned and know that pain VERY well. Most of us can imagine, to a degree, what it would feel like to burn alive, and unpleasant doesn't begin to describe it. Conversely, bullets and explosions are new. We didn't evolve alongside these threats, so they are not as deeply engrained. Most of us can't even begin to imagine a gunshot wound feel like.
I'm sure if you asked combat soldiers and veterans what's scarier, dying or being wounded by being shot, or dying or being wounded by a flamethrower, a large percent of them would say the flamethrower is scarier, in a different kind of way. And this bears in several videos I have seen over the years of bunkers being cleared by flamethrowers. I can't be sure (terrible memory), but I think a lot, maybe most of the videos I have seen, are the flamethrowing tanks. They will withstand the machine gun from the bunker, and get close, then everyone scatters, they don't even bother trying to defend. So, the single tank will quickly clear out several bunkers out of fear.
It's benefits greatly outweigh the risks, however, it has been judged inhumane, rightly so, I believe. Having it makes you a vulnerable target, but it terrifies the enemy and can cause surrender before confrontation begins. While, I am sure you can find footage of this in almost any WWII documentary on the Pacific Theater, as well as Vietnam, I also remember a book I read when I was a kid by a Marine, I forget which war, and he said something about the psychological effect of the weapon, if I can find which book, I'll link it here.