Exemple #1
0
def get_offline_manifest():
    global _offline_manifest
    if _offline_manifest is None:
        filename = get_offline_manifest_filename()
        if default_storage.exists(filename):
            _offline_manifest = simplejson.load(default_storage.open(filename))
        else:
            _offline_manifest = {}
    return _offline_manifest
Exemple #2
0
def get_offline_manifest():
    global _offline_manifest
    if _offline_manifest is None:
        filename = get_offline_manifest_filename()
        if default_storage.exists(filename):
            _offline_manifest = simplejson.load(default_storage.open(filename))
        else:
            _offline_manifest = {}
    return _offline_manifest
Exemple #3
0
def get_offline_manifest():
    global _offline_manifest
    if _offline_manifest is None:
        filename = get_offline_manifest_filename()
        if default_storage.exists(filename):
            with default_storage.open(filename) as fp:
                _offline_manifest = json.loads(fp.read().decode('utf8'))
        else:
            _offline_manifest = {}
    return _offline_manifest
Exemple #4
0
def get_offline_manifest():
    global _offline_manifest
    if _offline_manifest is None:
        filename = get_offline_manifest_filename()
        if default_storage.exists(filename):
            with default_storage.open(filename) as fp:
                _offline_manifest = json.loads(fp.read().decode('utf8'))
        else:
            _offline_manifest = {}
    return _offline_manifest
Exemple #5
0
def get_offline_manifest():
    filename = get_offline_manifest_filename()
    if default_storage.exists(filename):
        return simplejson.load(default_storage.open(filename))
    else:
        return {}
Exemple #6
0
def get_offline_manifest():
    filename = get_offline_manifest_filename()
    if default_storage.exists(filename):
        return simplejson.load(default_storage.open(filename))
    else:
        return {}