def get_consumption(self, location_id, aggregation, delta):
    'Update data from Smappee.'
    if (not self.is_remote_active):
        return
    end = datetime.utcnow()
    start = (end - timedelta(minutes=delta))
    try:
        return self._smappy.get_consumption(location_id, start, end, aggregation)
    except RequestException as error:
        _LOGGER.error('Error getting comsumption from Smappee cloud. (%s)', error)
Update data from Smappee.
def get_consumption(self, location_id, aggregation, delta):
    
    if (not self.is_remote_active):
        return
    end = datetime.utcnow()
    start = (end - timedelta(minutes=delta))
    try:
        return self._smappy.get_consumption(location_id, start, end, aggregation)
    except RequestException as error:
        _LOGGER.error('Error getting comsumption from Smappee cloud. (%s)', error)