def METHOD_NAME(data, games):
    if isinstance(data, list):
        return [METHOD_NAME(i, games) for i in data]
    elif isinstance(data, dict):
        return {key: METHOD_NAME(val, games) for key, val in data.items()}
    elif isinstance(data, str):
        game = get_game_by_hash(data, games)
        if game:
            return game
        else:
            return data
    else:
        return data