Skip to content

Commit

Permalink
Improve logging (#5299)
Browse files Browse the repository at this point in the history
* Improve Towny's Logging System.

* Improve encapsulation of Towny and TownyUniverse.

* Remove the old outpost checker.

* Undo re-ordered imports.

* A couple more import diffs.

* Fix errors with the new logger.

* Fixes & Improvements.

- TIE-specific messages not being logged to console.
- Skip changelog/updatingconfigversion when we're isError()'d.
- Javadoc not building.
- Specific TIEs for loading/saving database vs loading/saving
database.yml file.
- A typo.

* Drop the \'s down a notch.

Co-authored-by: Llm Dl <LlmDlio@gmail.com>
  • Loading branch information
Articdive and LlmDl authored Sep 29, 2021
1 parent 72825f5 commit 72f0189
Show file tree
Hide file tree
Showing 10 changed files with 354 additions and 326 deletions.
7 changes: 0 additions & 7 deletions resources/outpostschecked.txt

This file was deleted.

6 changes: 2 additions & 4 deletions src/com/palmergames/bukkit/config/CommentedConfiguration.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,18 +35,16 @@ public CommentedConfiguration(File file) {

public boolean load() {

boolean loaded = true;

try {
this.load(file);
} catch (InvalidConfigurationException | IOException e) {
Towny.getPlugin().getLogger().warning(String.format("Loading error: Failed to load file %s (does it pass a yaml parser?).", file.getPath()));
Towny.getPlugin().getLogger().warning("https://jsonformatter.org/yaml-parser");
Towny.getPlugin().getLogger().warning(e.getMessage());
loaded = false;
return false;
}

return loaded;
return true;
}

public void save() {
Expand Down
Loading

0 comments on commit 72f0189

Please sign in to comment.