Factor out hashtag resolution