def dot_expand()

in MessagePayload.py [0:0]


    def dot_expand(self, k, v):
        try:
            v = ast.literal_eval(v)
        except Exception as e:
            pass
        if len(k) == 0:
            return v
        
        keys = k.split('.')
        key = keys.pop(0)
        
        if len(keys) == 0:
            return { key: v }
        
        return { key: self.dot_expand(".".join(keys), v) }