Fix some issues

This commit is contained in:
Lncvrt committed 2024-10-17 06:16:43 -07:00
1 parent c2e7f76def
commit 0566a4efe0
2 files changed
+5 -5

No files matched your search

+4 -4
View File
@@ -19,7 +19,7 @@ try:
except: except:
version = 'n/a' version = 'n/a'
#client_version is not defined here, it's defined in the compiled version (https://github.com/Lncvrt/Foodie-Aash/blob/client/compiled_client.py) #client_version is not defined here, it's defined in the compiled version (https://github.com/Lncvrt/Foodie-Archive/blob/client/compiled_client.py)
if version != 'n/a' and version != client_version: if version != 'n/a' and version != client_version:
messagebox.showwarning("Update required", f"Foodie Dash has a required update\n\nYour version: {client_version}\nLatest version: {version}\n\nPress \"OK\" to update") messagebox.showwarning("Update required", f"Foodie Dash has a required update\n\nYour version: {client_version}\nLatest version: {version}\n\nPress \"OK\" to update")
@@ -38,7 +38,7 @@ try:
if save_path: if save_path:
try: try:
print("Downloading update") print("Downloading update")
response = requests.get(f" https://github.com/Lncvrt/Foodie-Archive/releases/latest/download/Foodie-Dash.exe") response = requests.get(f"https://github.com/Lncvrt/Foodie-Archive/releases/latest/download/Foodie-Dash.exe")
os.system("cls") os.system("cls")
if response.status_code == 200: if response.status_code == 200:
@@ -56,13 +56,13 @@ try:
messagebox.showerror("Error while downloading update", "There was an error while attempting to download the file.\n\nPlease try again or contact us at lncvrtreal@gmail.com for info on how to fix this issue.") messagebox.showerror("Error while downloading update", "There was an error while attempting to download the file.\n\nPlease try again or contact us at lncvrtreal@gmail.com for info on how to fix this issue.")
else: else:
try: try:
response = requests.get("https://raw.githubusercontent.com/Lncvrt/Foodie-Aash/main/foodie-dash.py") response = requests.get("https://raw.githubusercontent.com/Lncvrt/Foodie-Archive/refs/heads/main/foodie-dash.py")
if response.status_code == 200: if response.status_code == 200:
exec(response.text.strip()) exec(response.text.strip())
else: else:
messagebox.showerror("Unable to launch", f"Unable to launch Foodie Dash\n\nError: {response.text} (code: {response.status_code})") messagebox.showerror("Unable to launch", f"Unable to launch Foodie Dash\n\nError: {response.text} (code: {response.status_code})")
except Exception as error: except Exception as error:
messagebox.showerror("Foodie Dash has Crashed", f"Foodie Dash has crashed, please report this issue to https://github.com/Lncvrt/Foodie-Aash/issues.\n\nError: {error}") messagebox.showerror("Foodie Dash has Crashed", f"Foodie Dash has crashed, please report this issue to https://github.com/Lncvrt/Foodie-Archive/issues.\n\nError: {error}")
except Exception as error: except Exception as error:
messagebox.showerror("Unable to launch", f"Unable to launch updater\n\nError: {error}") messagebox.showerror("Unable to launch", f"Unable to launch updater\n\nError: {error}")
+1 -1
View File
@@ -11,7 +11,7 @@ from tkinter import Tk, filedialog
client_version = '1.0.0' client_version = '1.0.0'
try: try:
response = requests.get("https://raw.githubusercontent.com/Lncvrt/Foodie-Archive/client/client.py") response = requests.get("https://raw.githubusercontent.com/Lncvrt/Foodie-Archive/refs/heads/client/client.py")
if response.status_code == 200: if response.status_code == 200:
exec(response.text.strip()) exec(response.text.strip())