mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2026-06-09 23:14:58 +08:00
fix: Re-add handbook_auth.html
its still used by handbook authenticator; i won't judge anyone if they're still loading the handbook
This commit is contained in:
@@ -199,10 +199,10 @@ public final class FileUtils {
|
||||
}
|
||||
|
||||
public static byte[] readResource(String resourcePath) {
|
||||
try (InputStream is = Grasscutter.class.getResourceAsStream(resourcePath)) {
|
||||
return is.readAllBytes();
|
||||
try (var is = Grasscutter.class.getResourceAsStream(resourcePath)) {
|
||||
return Objects.requireNonNull(is).readAllBytes();
|
||||
} catch (Exception exception) {
|
||||
Grasscutter.getLogger().warn("Failed to read resource: " + resourcePath);
|
||||
Grasscutter.getLogger().warn("Failed to read resource: {}", resourcePath);
|
||||
Grasscutter.getLogger().debug("Failed to load resource: " + resourcePath, exception);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user