The thing about dpsing as a healer is that the party shouldn't even notice that a healer is doing it. If a party is noticing the healer isn't keeping them at whatever level is needed for them to perform their roles and is dpsing instead, then that healer has failed at the necessary balance between healing and dpsing. And especially in a party with randoms where we don't know how someone plays, it's better to err on the side of caution and keep that level higher than we might with friends.
In this particular case, it sounds like the tank was undergeared so parameters are slightly different. But it's a good general rule of thumb to focus on our main role first and balance that where we can with dps. Neither role we play should be to the detriment of the other.