def get_modified_time(storage, name):
    try:
        modified_time = storage.modified_time(name)
    except OSError:
        return 0
    except NotImplementedError:
        return None
    if modified_time and timezone.is_naive(modified_time):
        if getattr(settings, 'USE_TZ', False):
            default_timezone = timezone.get_default_timezone()
            return timezone.make_aware(modified_time, default_timezone)
    return modified_time
Get modified time from storage, ensuring the result is a timezone-aware
dataset/ETHPy150Open SmileyChris/easy-thumbnails/easy_thumbnails/utils.py/get_modified_time