Fix NPE in browser when no editor was set

This commit is contained in:
crschnick 2023-08-20 01:43:47 +00:00
parent a80c22f34c
commit f0e8385e2b

View file

@ -43,6 +43,7 @@ public class EditFileAction implements LeafAction {
@Override
public String getName(OpenFileSystemModel model, List<BrowserEntry> entries) {
return "Edit with " + AppPrefs.get().externalEditor().getValue().toTranslatedString();
var e = AppPrefs.get().externalEditor().getValue();
return "Edit with " + (e != null ? e.toTranslatedString() : "?");
}
}