I think that expressing thoughts for someone is absolutely fine. But offering prayers is making a BIG assumption about the recipient. I've personally had people offer me both thoughts and prayers when one of my parents passed, and I thanked them since they were just being caring, and which I really appreciated (the caring, not the prayers!).
Of course, the negative press around this phrase is that it does not translate into action. Such as when there's another mass shooting and thoughts and prayers are offered to those affected, but nothing happens in terms of a sensible debate on the factors that allowed such a thing to happen in the first place.
The time to think has come but prayer is a relic of primitive thought speaking to a wall or an invisible judge in the sky has changed anything therefore we need to think and act but if we don't have time for the thoughts and you would be a cold machine just acting not being