mirror of
https://github.com/esp8266/Arduino.git
synced 2025-06-16 11:21:18 +03:00
Fixed NPE when import menu are empty
This commit is contained in:
@ -988,6 +988,8 @@ public class Base {
|
||||
}
|
||||
|
||||
public void rebuildImportMenu(JMenu importMenu) {
|
||||
if (importMenu == null)
|
||||
return;
|
||||
importMenu.removeAll();
|
||||
|
||||
JMenuItem addLibraryMenuItem = new JMenuItem(_("Add Library..."));
|
||||
@ -1035,6 +1037,8 @@ public class Base {
|
||||
}
|
||||
|
||||
public void rebuildExamplesMenu(JMenu menu) {
|
||||
if (menu == null)
|
||||
return;
|
||||
try {
|
||||
menu.removeAll();
|
||||
|
||||
|
Reference in New Issue
Block a user