File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
src/main/java/org/openstreetmap/josm/plugins/scripting/preferences/graalvm Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -67,9 +67,10 @@ protected JPanel buildTabs() {
67
67
if (GraalVMFacadeFactory .isGraalVMPresent ()) {
68
68
tpPreferencesTabs .add (tr ("ES Module repositories" ),
69
69
pnlESModuleRepoConfiguration = new ESModuleRepoConfigurationPanel ());
70
+ tpPreferencesTabs .add (tr ("CommonJS module repositories" ),
71
+ pnlCommonJSRepoConfiguration = new CommonJSRepoConfigurationPanel ());
70
72
}
71
- tpPreferencesTabs .add (tr ("CommonJS module repositories" ),
72
- pnlCommonJSRepoConfiguration = new CommonJSRepoConfigurationPanel ());
73
+
73
74
pnl .add (tpPreferencesTabs , BorderLayout .CENTER );
74
75
return pnl ;
75
76
}
@@ -88,8 +89,12 @@ public GraalVMConfigurationPanel() {
88
89
* Persist preferences to the JOSM preferences file.
89
90
*/
90
91
public void persistToPreferences () {
91
- pnlCommonJSRepoConfiguration .persistToPreferences ();
92
- pnlESModuleRepoConfiguration .persistToPreferences ();
92
+ if (pnlCommonJSRepoConfiguration != null ) {
93
+ pnlCommonJSRepoConfiguration .persistToPreferences ();
94
+ }
95
+ if (pnlESModuleRepoConfiguration != null ) {
96
+ pnlESModuleRepoConfiguration .persistToPreferences ();
97
+ }
93
98
}
94
99
95
100
@ Override
You can’t perform that action at this time.
0 commit comments