<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _remove_redundancy(self, log):
 """Removes duplicate data from 'data' inside log dict and brings it out. {'data': {'a': 1, 'b': 2}, 'type': 'metric', 'id': 46846876} """

        for key in log:
            if key in log and key in log['data']:
                log[key] = log['data'].pop(key)
        return log