Skip to content

Commit

Permalink
circular import fix
Browse files Browse the repository at this point in the history
  • Loading branch information
andiricum2 committed Sep 4, 2023
1 parent fd881a7 commit c7760b7
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions piemc/update.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# @link http://www.PieMC-Dev.github.io/

import requests
from piemc.server import __version__
import piemc.server

repo_url = "https://api.github.com/repos/PieMC-Dev/PieMC/releases"

Expand Down Expand Up @@ -44,7 +44,7 @@ def check_for_updates():
latest_release = releases[0]
latest_release_version = latest_release["tag_name"]

current_release_version = __version__
current_release_version = piemc.server.__version__

if compare_versions(current_release_version, latest_release_version) < 0:
print("⚠️\033[33mNew version available:\033[0m", latest_release_version)
Expand All @@ -54,6 +54,3 @@ def check_for_updates():
print("No releases found for the repository.")
else:
print("Failed to retrieve repository information.")

if __name__ == "__main__":
check_for_updates()

0 comments on commit c7760b7

Please sign in to comment.