File tree Expand file tree Collapse file tree 1 file changed +7
-9
lines changed
worldguard-bukkit/src/main/java/com/sk89q/worldguard/bukkit Expand file tree Collapse file tree 1 file changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -228,23 +228,21 @@ private void setupCustomCharts(Metrics metrics) {
228228 return driver instanceof DirectoryYamlDriver ? "yaml" : driver instanceof SQLDriver ? "sql" : "unknown" ;
229229 }));
230230 metrics .addCustomChart (new Metrics .SimpleBarChart ("blacklist" , () -> {
231- int unused = 0 ;
232- int standard = 0 ;
233- int whitelist = 0 ;
231+ int blacklisted = 0 ;
232+ int whitelisted = 0 ;
234233 for (BukkitWorldConfiguration worldConfig : platform .getGlobalStateManager ().getWorldConfigs ()) {
235234 Blacklist blacklist = worldConfig .getBlacklist ();
236235 if (blacklist == null || blacklist .isEmpty ()) {
237- unused ++ ;
236+ continue ;
238237 } else if (blacklist .isWhitelist ()) {
239- whitelist ++ ;
238+ whitelisted += blacklist . getItemCount () ;
240239 } else {
241- standard ++ ;
240+ blacklisted += blacklist . getItemCount () ;
242241 }
243242 }
244243 Map <String , Integer > blacklistCounts = new HashMap <>();
245- blacklistCounts .put ("unused" , unused );
246- blacklistCounts .put ("blacklist" , standard );
247- blacklistCounts .put ("whitelist" , whitelist );
244+ blacklistCounts .put ("blacklist" , blacklisted );
245+ blacklistCounts .put ("whitelist" , whitelisted );
248246 return blacklistCounts ;
249247 }));
250248 metrics .addCustomChart (new Metrics .SimplePie ("chest_protection" , () ->
You can’t perform that action at this time.
0 commit comments