Skip to content

Commit cff0c15

Browse files
committed
Change to uppercase
1 parent fda9099 commit cff0c15

1 file changed

Lines changed: 12 additions & 12 deletions

File tree

src/org/netbeans/modules/php/wordpress/commands/WordPressCli.java

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ public final class WordPressCli {
110110

111111
// XXX default?
112112
private final List<String> DEFAULT_PARAMS = Collections.emptyList();
113-
private static final List<FrameworkCommand> commandsCache = new ArrayList<>();
113+
private static final List<FrameworkCommand> COMMANDS_CACHE = new ArrayList<>();
114114

115115
private WordPressCli(String wpCliPath) {
116116
this.wpCliPath = wpCliPath;
@@ -319,10 +319,10 @@ public String getHelp(List<String> commands) {
319319
*/
320320
@NbBundle.Messages("WordPressCli.commands.empty=Please check whether config file and DB settings exist.")
321321
public List<FrameworkCommand> getCommands(boolean isForce) {
322-
if (!isForce && !commandsCache.isEmpty()) {
323-
return commandsCache;
322+
if (!isForce && !COMMANDS_CACHE.isEmpty()) {
323+
return COMMANDS_CACHE;
324324
}
325-
commandsCache.clear();
325+
COMMANDS_CACHE.clear();
326326
if (!isForce) {
327327
// exists xml?
328328
String commandList = WordPressOptions.getInstance().getWpCliCommandList();
@@ -341,34 +341,34 @@ public List<FrameworkCommand> getCommands(boolean isForce) {
341341
// parse
342342
FileInputStream fileInputStream = new FileInputStream(temp);
343343
InputStreamReader inputStreamReader = new InputStreamReader(fileInputStream, "UTF-8"); // NOI18N
344-
WordPressCliCommandsXmlParser.parse(inputStreamReader, commandsCache);
344+
WordPressCliCommandsXmlParser.parse(inputStreamReader, COMMANDS_CACHE);
345345
} finally {
346346
temp.deleteOnExit();
347347
}
348348
} catch (IOException ex) {
349349
Exceptions.printStackTrace(ex);
350350
}
351-
if (!commandsCache.isEmpty()) {
352-
return commandsCache;
351+
if (!COMMANDS_CACHE.isEmpty()) {
352+
return COMMANDS_CACHE;
353353
}
354354
}
355355
}
356356

357357
// update
358358
updateCommands();
359359

360-
return commandsCache;
360+
return COMMANDS_CACHE;
361361
}
362362

363363
public void updateCommands() {
364-
commandsCache.clear();
365-
getCommands(Collections.<String>emptyList(), commandsCache);
366-
if (commandsCache.isEmpty()) {
364+
COMMANDS_CACHE.clear();
365+
getCommands(Collections.<String>emptyList(), COMMANDS_CACHE);
366+
if (COMMANDS_CACHE.isEmpty()) {
367367
NotifyDescriptor.Message message = new NotifyDescriptor.Message(Bundle.WordPressCli_commands_empty(), NotifyDescriptor.WARNING_MESSAGE);
368368
DialogDisplayer.getDefault().notify(message);
369369
} else {
370370
WordPressCliCommandListXmlBuilder builder = new WordPressCliCommandListXmlBuilder();
371-
builder.build(commandsCache);
371+
builder.build(COMMANDS_CACHE);
372372
String commadlist = builder.asText();
373373
if (!StringUtils.isEmpty(commadlist)) {
374374
WordPressOptions.getInstance().setWpCliCommandList(commadlist);

0 commit comments

Comments
 (0)