diff --git a/composer.lock b/composer.lock index bbb56a4d..7b67c5fa 100644 --- a/composer.lock +++ b/composer.lock @@ -12,12 +12,12 @@ "source": { "type": "git", "url": "https://github.com/aternosorg/codex.git", - "reference": "99f858ed4a14e5f8ac5293c0abb528b516347c90" + "reference": "c8715d8d29dc10744b7221b705b90c2a53eab57c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/aternosorg/codex/zipball/99f858ed4a14e5f8ac5293c0abb528b516347c90", - "reference": "99f858ed4a14e5f8ac5293c0abb528b516347c90", + "url": "https://api.github.com/repos/aternosorg/codex/zipball/c8715d8d29dc10744b7221b705b90c2a53eab57c", + "reference": "c8715d8d29dc10744b7221b705b90c2a53eab57c", "shasum": "" }, "require": { @@ -47,7 +47,7 @@ "issues": "https://github.com/aternosorg/codex/issues", "source": "https://github.com/aternosorg/codex/tree/2.0" }, - "time": "2022-08-16T15:33:25+00:00" + "time": "2022-08-16T16:33:26+00:00" } ], "packages-dev": [ diff --git a/src/Analysis/Information/Quilt/QuiltInformation.php b/src/Analysis/Information/Quilt/QuiltInformation.php index ff1d8b77..de01aa1a 100644 --- a/src/Analysis/Information/Quilt/QuiltInformation.php +++ b/src/Analysis/Information/Quilt/QuiltInformation.php @@ -2,12 +2,14 @@ namespace Aternos\Codex\Minecraft\Analysis\Information\Quilt; +use Aternos\Codex\Minecraft\Analysis\Information\Vanilla\VanillaInformation; + /** * Class QuiltInformation * * @package Aternos\Codex\Minecraft\Analysis\Information\Quilt */ -abstract class QuiltInformation extends \Aternos\Codex\Minecraft\Analysis\Information\Vanilla\VanillaInformation +abstract class QuiltInformation extends VanillaInformation { } \ No newline at end of file diff --git a/src/Analysis/Information/Quilt/QuiltVanillaVersionInformation.php b/src/Analysis/Information/Quilt/QuiltVanillaVersionInformation.php index a1f19f3d..13cb6157 100644 --- a/src/Analysis/Information/Quilt/QuiltVanillaVersionInformation.php +++ b/src/Analysis/Information/Quilt/QuiltVanillaVersionInformation.php @@ -2,12 +2,14 @@ namespace Aternos\Codex\Minecraft\Analysis\Information\Quilt; +use Aternos\Codex\Minecraft\Analysis\Information\Vanilla\VanillaVersionInformation; + /** * Class QuiltVanillaVersionInformation * * @package Aternos\Codex\Minecraft\Analysis\Information\Quilt */ -class QuiltVanillaVersionInformation extends \Aternos\Codex\Minecraft\Analysis\Information\Vanilla\VanillaVersionInformation +class QuiltVanillaVersionInformation extends VanillaVersionInformation { /** * @inheritDoc diff --git a/src/Analysis/Problem/CrashReport/CrashReportProblem.php b/src/Analysis/Problem/CrashReport/CrashReportProblem.php index fc8b9c36..c29967c2 100644 --- a/src/Analysis/Problem/CrashReport/CrashReportProblem.php +++ b/src/Analysis/Problem/CrashReport/CrashReportProblem.php @@ -2,11 +2,13 @@ namespace Aternos\Codex\Minecraft\Analysis\Problem\CrashReport; +use Aternos\Codex\Minecraft\Analysis\Problem\MinecraftProblem; + /** * Class CrashReportProblem * * @package Aternos\Codex\Minecraft\Analysis\Problem\CrashReport */ -abstract class CrashReportProblem extends \Aternos\Codex\Minecraft\Analysis\Problem\MinecraftProblem +abstract class CrashReportProblem extends MinecraftProblem { } \ No newline at end of file diff --git a/src/Analysis/Solution/CrashReport/CrashReportSolution.php b/src/Analysis/Solution/CrashReport/CrashReportSolution.php index 503f6e7e..47552696 100644 --- a/src/Analysis/Solution/CrashReport/CrashReportSolution.php +++ b/src/Analysis/Solution/CrashReport/CrashReportSolution.php @@ -2,12 +2,14 @@ namespace Aternos\Codex\Minecraft\Analysis\Solution\CrashReport; +use Aternos\Codex\Minecraft\Analysis\Solution\MinecraftSolution; + /** * Class CrashReportSolution * * @package Aternos\Codex\Minecraft\Analysis\Solution\CrashReport */ -abstract class CrashReportSolution extends \Aternos\Codex\Minecraft\Analysis\Solution\MinecraftSolution +abstract class CrashReportSolution extends MinecraftSolution { } \ No newline at end of file diff --git a/src/Log/Minecraft/MinecraftLog.php b/src/Log/Minecraft/MinecraftLog.php index 0eb21753..89348582 100644 --- a/src/Log/Minecraft/MinecraftLog.php +++ b/src/Log/Minecraft/MinecraftLog.php @@ -5,8 +5,8 @@ use Aternos\Codex\Analyser\AnalyserInterface; use Aternos\Codex\Analyser\PatternAnalyser; use Aternos\Codex\Analysis\InformationInterface; -use Aternos\Codex\Analysis\InsightInterface; use Aternos\Codex\Detective\LinePatternDetector; +use Aternos\Codex\Log\AnalysableLog; use Aternos\Codex\Log\DetectableLogInterface; use Aternos\Codex\Minecraft\Log\Type\ClientLogTypeInterface; use Aternos\Codex\Minecraft\Log\Type\ContentLogTypeInterface; @@ -21,7 +21,7 @@ * * @package Aternos\Codex\Minecraft\Log\Minecraft */ -class MinecraftLog extends \Aternos\Codex\Log\AnalysableLog implements DetectableLogInterface +class MinecraftLog extends AnalysableLog implements DetectableLogInterface { protected static string $pattern; diff --git a/src/Log/Minecraft/Vanilla/Fabric/FabricServerLog.php b/src/Log/Minecraft/Vanilla/Fabric/FabricServerLog.php index 8faa1125..ce9e39a2 100644 --- a/src/Log/Minecraft/Vanilla/Fabric/FabricServerLog.php +++ b/src/Log/Minecraft/Vanilla/Fabric/FabricServerLog.php @@ -2,11 +2,13 @@ namespace Aternos\Codex\Minecraft\Log\Minecraft\Vanilla\Fabric; +use Aternos\Codex\Minecraft\Log\Type\ServerLogTypeInterface; + /** * Class FabricServerLog * * @package Aternos\Codex\Minecraft\Log\Minecraft\Fabric */ -class FabricServerLog extends FabricLog implements \Aternos\Codex\Minecraft\Log\Type\ServerLogTypeInterface +class FabricServerLog extends FabricLog implements ServerLogTypeInterface { } \ No newline at end of file diff --git a/src/Log/Minecraft/Vanilla/Quilt/QuiltLog.php b/src/Log/Minecraft/Vanilla/Quilt/QuiltLog.php index 6865f971..77149d05 100644 --- a/src/Log/Minecraft/Vanilla/Quilt/QuiltLog.php +++ b/src/Log/Minecraft/Vanilla/Quilt/QuiltLog.php @@ -7,7 +7,6 @@ use Aternos\Codex\Minecraft\Analyser\QuiltAnalyser; use Aternos\Codex\Minecraft\Analysis\Information\Vanilla\VanillaVersionInformation; use Aternos\Codex\Minecraft\Log\Minecraft\Vanilla\VanillaLog; -use Aternos\Codex\Minecraft\Log\Minecraft\Vanilla\VanillaServerLog; /** * Class QuiltLog diff --git a/src/Parser/CrashReportLevel.php b/src/Parser/CrashReportLevel.php index 984959a1..282dc0e4 100644 --- a/src/Parser/CrashReportLevel.php +++ b/src/Parser/CrashReportLevel.php @@ -9,7 +9,7 @@ * * @package Aternos\Codex\Minecraft\Log\CrashReport */ -enum CrashReportLevel: int implements \Aternos\Codex\Log\LevelInterface +enum CrashReportLevel: int implements LevelInterface { case WARNING = 4; case INFO = 6; diff --git a/src/Translator/Translator.php b/src/Translator/Translator.php index 2402ae06..6636d7f1 100644 --- a/src/Translator/Translator.php +++ b/src/Translator/Translator.php @@ -2,6 +2,8 @@ namespace Aternos\Codex\Minecraft\Translator; +use InvalidArgumentException; + /** * Class Translator * @@ -64,7 +66,7 @@ public function getLanguage(): string public function setLanguage(string $language = self::DEFAULT_LANGUAGE): static { if (!$this->checkTranslationFile($language)) { - throw new \InvalidArgumentException("Language file for language '" . $language . "' not found."); + throw new InvalidArgumentException("Language file for language '" . $language . "' not found."); } $this->language = $language; return $this; @@ -87,7 +89,7 @@ public function getTranslation(string $variable, array $replacements = []): stri if ($this->getLanguage() !== static::DEFAULT_LANGUAGE) { return static::getFallbackInstance()->getTranslation($variable, $replacements); } - throw new \InvalidArgumentException("Translation variable '" . $variable . "' not found."); + throw new InvalidArgumentException("Translation variable '" . $variable . "' not found."); } $value = $translations[$variable]; @@ -133,7 +135,7 @@ protected function loadTranslations(): array $content = file_get_contents($file); $translations = json_decode($content, true); if (!is_array($translations)) { - throw new \InvalidArgumentException("Could not parse JSON translation file: " . $file); + throw new InvalidArgumentException("Could not parse JSON translation file: " . $file); } $this->translations[$this->language] = $translations;