diff --git a/README.md b/README.md index d6cdce9..e7d2637 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ This plugin is now supported in [Godot Extended Library Discord](https://discord A complete GitHub integration for your Godot Editor! Manage your project without even opening your browser. Author: *"Nicolo (fenix) Santilio"* -Version: *1.3.6* +Version: *1.3.7* Wiki: *[supported](https://github.com/fenix-hub/godot-engine.github-integration/wiki)* Godot Version: *3.2.3stable* diff --git a/addons/github-integration/plugin.cfg b/addons/github-integration/plugin.cfg index 9d7e3c2..7e8c116 100644 --- a/addons/github-integration/plugin.cfg +++ b/addons/github-integration/plugin.cfg @@ -3,5 +3,5 @@ name="GitHub integration" description="Plugin to integrate GitHub requests directly via Godot Engine Editor" author="Nicolo (fenix) Santilio" -version="1.3.6" +version="1.3.7" script="scripts/github-integration.gd" diff --git a/addons/github-integration/scripts/Commit.gd b/addons/github-integration/scripts/Commit.gd index 15a55bd..6b45e95 100644 --- a/addons/github-integration/scripts/Commit.gd +++ b/addons/github-integration/scripts/Commit.gd @@ -116,7 +116,7 @@ func connect_signals(): func request_completed(result, response_code, headers, body ): get_parent().print_debug_message("REQUEST TO API : Request exited with code %s" % response_code) if response_code == 422: - get_parent().print_debug_message(str(JSON.parse(body.get_string_from_utf8()).result)) + get_parent().print_debug_message(JSON.parse(body.get_string_from_utf8()).result) if result == 0: match requesting: REQUESTS.UPLOAD: @@ -209,7 +209,7 @@ func request_completed(result, response_code, headers, body ): Loading.hide() -func load_branches(br : Array, s_r : RepositoryItem, ct : Array, gitignore : Dictionary) : +func load_branches(br : Array, s_r : PanelContainer, ct : Array, gitignore : Dictionary) : _branch.clear() repo_selected = s_r._repository branches_contents = ct diff --git a/addons/github-integration/scripts/Notifications.gd b/addons/github-integration/scripts/Notifications.gd index dfd3f1b..c6684c2 100644 --- a/addons/github-integration/scripts/Notifications.gd +++ b/addons/github-integration/scripts/Notifications.gd @@ -106,8 +106,8 @@ func _on_timeout(): request_notifications() func request_notifications() -> void: - if not PluginSettings.auto_update_notifications: - return + if not PluginSettings.auto_update_notifications: return + if UserData.USER == {} : return get_parent().print_debug_message("loading notifications, please wait...") emit_signal("add_notifications",-get_parent().Header.notifications) RestHandler.request_invitations_list() diff --git a/addons/github-integration/scripts/Repo.gd b/addons/github-integration/scripts/Repo.gd index 5ae0192..842a0f8 100644 --- a/addons/github-integration/scripts/Repo.gd +++ b/addons/github-integration/scripts/Repo.gd @@ -68,7 +68,7 @@ var contributor_class : PackedScene = load("res://addons/github-integration/scen enum REQUESTS { REPOS = 0, GISTS = 1, UP_REPOS = 2, UP_GISTS = 3, DELETE = 4, COMMIT = 5, BRANCHES = 6, CONTENTS = 7, TREES = 8, DELETE_RESOURCE = 9, END = -1 , FILE_CONTENT = 10 ,NEW_BRANCH = 11 , PULLING = 12, COLLABORATOR = 13 } var requesting -var current_repo : RepositoryItem +var current_repo : PanelContainer var html : String var current_branch var branches = [] @@ -146,7 +146,7 @@ func load_icons(r : Dictionary): git_lfs.set_button_icon(IconLoaderGithub.load_icon_from_name("git_lfs-gray")) add_collaborator_btn.set_button_icon(IconLoaderGithub.load_icon_from_name("add-gray")) -func open_repository(repository_item : RepositoryItem) -> void: +func open_repository(repository_item : PanelContainer) -> void: _clear() # Load repository's info .... diff --git a/addons/github-integration/scripts/UserPanel.gd b/addons/github-integration/scripts/UserPanel.gd index b145372..815bf0e 100644 --- a/addons/github-integration/scripts/UserPanel.gd +++ b/addons/github-integration/scripts/UserPanel.gd @@ -161,7 +161,7 @@ func new_repo(): RepoDialog.popup() # Items clicked ............................... -func repo_clicked(clicked_repo : RepositoryItem): +func repo_clicked(clicked_repo : PanelContainer): for repository in repository_list: if repository!=clicked_repo: repository.deselect() @@ -172,7 +172,7 @@ func gist_clicked(clicked_gist : GistItem): gist.deselect() # Items selected ............................... -func repo_selected(repository : RepositoryItem): +func repo_selected(repository : PanelContainer): get_parent().print_debug_message("opening selected repository...") get_parent().loading(true) get_parent().Repo.open_repository(repository) diff --git a/addons/github-integration/scripts/user_data.gd b/addons/github-integration/scripts/user_data.gd index 944ac08..01da933 100644 --- a/addons/github-integration/scripts/user_data.gd +++ b/addons/github-integration/scripts/user_data.gd @@ -20,7 +20,7 @@ var directory : String = "" var file_name : String = "user_data.ud" var avatar_name : String = "avatar" -var USER : Dictionary +var USER : Dictionary = {} # --- on the USER usage # login = username