mirror of
https://github.com/partitioncloud/partitioncloud-server.git
synced 2025-01-23 17:26:26 +01:00
Fix errors
This commit is contained in:
parent
121fa288d2
commit
a7df482f29
@ -85,6 +85,7 @@ def online_search(query):
|
|||||||
pass
|
pass
|
||||||
except urllib.error.HTTPError as e:
|
except urllib.error.HTTPError as e:
|
||||||
print(e)
|
print(e)
|
||||||
|
break
|
||||||
return partitions
|
return partitions
|
||||||
|
|
||||||
|
|
||||||
@ -101,8 +102,14 @@ def flush_cache():
|
|||||||
).fetchall()
|
).fetchall()
|
||||||
for element in expired_cache:
|
for element in expired_cache:
|
||||||
uuid = element["uuid"]
|
uuid = element["uuid"]
|
||||||
|
try:
|
||||||
os.remove(f"partitioncloud/search-partitions/{uuid}.pdf")
|
os.remove(f"partitioncloud/search-partitions/{uuid}.pdf")
|
||||||
|
except FileNotFoundError:
|
||||||
|
pass
|
||||||
|
try:
|
||||||
os.remove(f"partitioncloud/static/search-thumbnails/{uuid}.jpg")
|
os.remove(f"partitioncloud/static/search-thumbnails/{uuid}.jpg")
|
||||||
|
except FileNotFoundError:
|
||||||
|
pass
|
||||||
|
|
||||||
db.execute(
|
db.execute(
|
||||||
"""
|
"""
|
||||||
|
Loading…
Reference in New Issue
Block a user