Skip to content

Commit

Permalink
Fix crash that happened if joining a workspace from the quick menu wi…
Browse files Browse the repository at this point in the history
…thout a project.
  • Loading branch information
ggreer committed Aug 26, 2020
1 parent 86e106f commit e92bb4a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/floobits/FloobitsApplication.java
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ public void joinWorkspace(final ContextImpl context, final String url) {
try {
f = new FlooUrl(url);
} catch (Throwable e) {
Flog.errorMessage(String.format("Invalid url: %s", e), context.project);
Flog.errorMessage(String.format("Invalid url: %s", e), context != null ? context.project : null);
return;
}

Expand Down
3 changes: 2 additions & 1 deletion src/floobits/utilities/Flog.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
import floobits.common.FloorcJson;
import floobits.common.Utils;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

import javax.swing.*;
import javax.swing.event.HyperlinkEvent;
Expand Down Expand Up @@ -72,7 +73,7 @@ public static void info (String s, Object... args) {
private static void ensureRegistered() {
NotificationsConfiguration.getNotificationsConfiguration().register(ID, NotificationDisplayType.BALLOON, false);
}
public static void statusMessage(final String message, final NotificationType notificationType, final Project project) {
public static void statusMessage(final String message, final NotificationType notificationType, @Nullable final Project project) {
ApplicationManager.getApplication().invokeLater(new Runnable() {
@Override
public void run() {
Expand Down

0 comments on commit e92bb4a

Please sign in to comment.