# Path: mapmyfitness/utils.py
# def datetime_to_iso_format(dt):
#     utc_datetime = dt.replace(tzinfo=utc)
#     return utc_datetime.isoformat()


import copy
from .utils import datetime_to_iso_format
        from .api.workout import aggregate_values
        self.inflate()


class RouteInflator(BaseInflator):
    def inflate(self):
        inflated = copy.deepcopy(self.initial_obj)

        inflated['starting_location'] = {
            'type': 'Point',
            'coordinates': [
                inflated['points'][0]['lng'],
                inflated['points'][0]['lat']
            ]
        }

        inflated.setdefault('_links', {})

        inflated['_links']['privacy'] = [{
            'href': '/v7.0/privacy_option/{0}/'.format(inflated['privacy']),
            'id': '{0}'.format(inflated['privacy'])
        }]

        self.inflated = inflated


class WorkoutInflator(BaseInflator):
    def inflate(self):
        # TODO: Ugh, too late to deal with cirular imports
        inflated = copy.deepcopy(self.initial_obj)


# Path: mapmyfitness/utils.py
# def datetime_to_iso_format(dt):
#     utc_datetime = dt.replace(tzinfo=utc)
#     return utc_datetime.isoformat()


# Path: mapmyfitness/inflators.py
import copy
from .utils import datetime_to_iso_format
        from .api.workout import aggregate_values

        self.inflate()


class RouteInflator(BaseInflator):
    def inflate(self):
        inflated = copy.deepcopy(self.initial_obj)

        inflated['starting_location'] = {
            'type': 'Point',
            'coordinates': [
                inflated['points'][0]['lng'],
                inflated['points'][0]['lat']
            ]
        }

        inflated.setdefault('_links', {})

        inflated['_links']['privacy'] = [{
            'href': '/v7.0/privacy_option/{0}/'.format(inflated['privacy']),
            'id': '{0}'.format(inflated['privacy'])
        }]

        self.inflated = inflated


class WorkoutInflator(BaseInflator):
    def inflate(self):
        # TODO: Ugh, too late to deal with cirular imports
        inflated = copy.deepcopy(self.initial_obj)


        inflated['start_datetime'] = datetime_to_iso_format(inflated['start_datetime'])