mirror of
https://gitlab.com/mangadex-pub/mangadex_at_home.git
synced 2024-01-19 02:48:37 +00:00
Applied spotlessJava
This commit is contained in:
parent
d27cd91947
commit
8b655575e1
9
src/main/java/mdnet/cache/DiskLruCache.java
vendored
9
src/main/java/mdnet/cache/DiskLruCache.java
vendored
|
@ -410,7 +410,8 @@ public final class DiskLruCache implements Closeable {
|
|||
/**
|
||||
* Returns a snapshot of the entry named {@code key}, or null if it doesn't
|
||||
* exist is not currently readable. If a value is returned, it is moved to the
|
||||
* head of the LRU queue. Unsafe as it allows arbitrary directories to be accessed!
|
||||
* head of the LRU queue. Unsafe as it allows arbitrary directories to be
|
||||
* accessed!
|
||||
*/
|
||||
public Snapshot getUnsafe(String key) throws IOException {
|
||||
validateUnsafeKey(key);
|
||||
|
@ -611,7 +612,8 @@ public final class DiskLruCache implements Closeable {
|
|||
|
||||
/**
|
||||
* Drops the entry for {@code key} if it exists and can be removed. Entries
|
||||
* actively being edited cannot be removed. Unsafe as it allows arbitrary directories to be accessed!
|
||||
* actively being edited cannot be removed. Unsafe as it allows arbitrary
|
||||
* directories to be accessed!
|
||||
*
|
||||
* @return true if an entry was removed.
|
||||
*/
|
||||
|
@ -707,7 +709,8 @@ public final class DiskLruCache implements Closeable {
|
|||
private void validateUnsafeKey(String key) {
|
||||
Matcher matcher = UNSAFE_LEGAL_KEY_PATTERN.matcher(key);
|
||||
if (!matcher.matches()) {
|
||||
throw new IllegalArgumentException("Unsafe keys must match regex " + UNSAFE_LEGAL_KEY_PATTERN + ": \"" + key + "\"");
|
||||
throw new IllegalArgumentException(
|
||||
"Unsafe keys must match regex " + UNSAFE_LEGAL_KEY_PATTERN + ": \"" + key + "\"");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,7 +1,13 @@
|
|||
package mdnet.base
|
||||
|
||||
import io.netty.bootstrap.ServerBootstrap
|
||||
import io.netty.channel.*
|
||||
import io.netty.channel.ChannelFactory
|
||||
import io.netty.channel.ChannelFuture
|
||||
import io.netty.channel.ChannelHandlerContext
|
||||
import io.netty.channel.ChannelInboundHandlerAdapter
|
||||
import io.netty.channel.ChannelInitializer
|
||||
import io.netty.channel.ChannelOption
|
||||
import io.netty.channel.ServerChannel
|
||||
import io.netty.channel.nio.NioEventLoopGroup
|
||||
import io.netty.channel.socket.SocketChannel
|
||||
import io.netty.channel.socket.nio.NioServerSocketChannel
|
||||
|
@ -11,7 +17,6 @@ import io.netty.handler.codec.http.HttpServerCodec
|
|||
import io.netty.handler.codec.http.HttpServerKeepAliveHandler
|
||||
import io.netty.handler.ssl.SslContextBuilder
|
||||
import io.netty.handler.stream.ChunkedWriteHandler
|
||||
import io.netty.handler.timeout.IdleStateHandler
|
||||
import io.netty.handler.traffic.GlobalTrafficShapingHandler
|
||||
import io.netty.handler.traffic.TrafficCounter
|
||||
import mdnet.base.settings.ClientSettings
|
||||
|
|
Loading…
Reference in a new issue