When you are trying to comfort a friend, it’s important not to dismiss the pain they are feeling by saying something like “time heals everything”.
The reason why we try to minimize or dismiss other’s pain is that you are feeling the pain, or thinking about how hard it is, or relating it to a situation you’ve experienced in the past. It’s your own negative or sad feelings that are surfacing and making you feel bad. It’s a natural response to shut it down.
The first key in being there for someone is to separate your experiences from the person you are consoling. Be intentional about putting the focus on them.