mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[github] Handle GithubShareAction result in EDT: show error or refresh need to be called from there.
This commit is contained in:
@@ -237,19 +237,19 @@ public class GithubShareAction extends DumbAwareAction {
|
||||
gitPushHandler.addParameters("-u", "origin", "master");
|
||||
GitPushUtils.trackPushRejectedAsError(gitPushHandler, "Rejected push (" + root.getPresentableUrl() + "): ");
|
||||
errors.addAll(GitHandlerUtil.doSynchronouslyWithExceptions(gitPushHandler));
|
||||
if (!errors.isEmpty()) {
|
||||
ApplicationManager.getApplication().invokeLater(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
GitUIUtil.showOperationErrors(project, errors, GitBundle.getString("push.active.pushing"));
|
||||
if (!errors.isEmpty()) {
|
||||
GitUIUtil.showOperationErrors(project, errors, GitBundle.getString("push.active.pushing"));
|
||||
}
|
||||
else {
|
||||
RefreshAction.doRefresh(project);
|
||||
Notifications.Bus.notify(new Notification("github", "Success", "Successfully created project ''" + name + "'' on github",
|
||||
NotificationType.INFORMATION));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
else {
|
||||
RefreshAction.doRefresh(project);
|
||||
Notifications.Bus.notify(new Notification("github", "Success", "Successfully created project ''" + name + "'' on github",
|
||||
NotificationType.INFORMATION));
|
||||
}
|
||||
}
|
||||
}.queue();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user