Parse through a message and return a dict with data ready to be
        displayed through the terminal. Messages can be of either type
        praw.objects.Message or praw.object.Comment. The comments returned will
        contain special fields unique to messages and can't be parsed as normal
        comment objects.

def strip_praw_message(cls, msg):
        """
        Parse through a message and return a dict with data ready to be
        displayed through the terminal. Messages can be of either type
        praw.objects.Message or praw.object.Comment. The comments returned will
        contain special fields unique to messages and can't be parsed as normal
        comment objects.
        """
        author = getattr(msg, 'author', None)

        data = {}
        data['object'] = msg

        if isinstance(msg, praw.objects.Message):
            data['type'] = 'Message'
            data['level'] = msg.nested_level
            data['distinguished'] = msg.distinguished
            data['permalink'] = None
            data['submission_permalink'] = None
            data['subreddit_name'] = None
            data['link_title'] = None
            data['context'] = None
        else:
            data['type'] = 'InboxComment'
            data['level'] = 0
            data['distinguished'] = None
            data['permalink'] = msg._fast_permalink
            data['submission_permalink'] = '/'.join(data['permalink'].split('/')[:-2])
            data['subreddit_name'] = msg.subreddit_name_prefixed
            data['link_title'] = msg.link_title
            data['context'] = msg.context

        data['id'] = msg.id
        data['subject'] = msg.subject
        data['body'] = msg.body
        data['html'] = msg.body_html
        data['created'] = cls.humanize_timestamp(msg.created_utc)
        data['created_long'] = cls.humanize_timestamp(msg.created_utc, True)
        data['recipient'] = msg.dest
        data['distinguished'] = msg.distinguished
        data['author'] = author.name if author else '[deleted]'
        data['is_new'] = msg.new
        data['was_comment'] = msg.was_comment
        return data