I'd say these are completely different situations.

The Pharisees prayed publicly to gain the favor of other people. This man appears to have prayed to glorify God, in a culture that openly hates Him, probably knowing full well there would be strong pushback, but loving God enough to do so anyway.

As should we all.

Aspiring student of Christ