refactor(boot): frappe.cache() -> frappe.cache
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
This commit is contained in:
parent
7dddc9e4f1
commit
886d4ffc25
1 changed files with 2 additions and 2 deletions
|
|
@ -450,12 +450,12 @@ def get_marketplace_apps():
|
|||
return request.json()["message"]
|
||||
|
||||
try:
|
||||
apps = frappe.cache().get_value(cache_key, get_apps_from_fc, shared=True)
|
||||
apps = frappe.cache.get_value(cache_key, get_apps_from_fc, shared=True)
|
||||
installed_apps = set(frappe.get_installed_apps())
|
||||
apps = [app for app in apps if app["name"] not in installed_apps]
|
||||
except Exception:
|
||||
# Don't retry for a day
|
||||
frappe.cache().set_value(cache_key, apps, shared=True, expires_in_sec=24 * 60 * 60)
|
||||
frappe.cache.set_value(cache_key, apps, shared=True, expires_in_sec=24 * 60 * 60)
|
||||
|
||||
return apps
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue