X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Ffcp%2FGetLocalSonesCommand.java;h=3ef919ec74fbfadb6e403546b56d3b4503106d88;hp=46190044539c879ec2bda11d898d210ef3bd5ff7;hb=HEAD;hpb=a47643aed43d118ca68044f95451bb5374cdb332 diff --git a/src/main/java/net/pterodactylus/sone/fcp/GetLocalSonesCommand.java b/src/main/java/net/pterodactylus/sone/fcp/GetLocalSonesCommand.java index 4619004..3ef919e 100644 --- a/src/main/java/net/pterodactylus/sone/fcp/GetLocalSonesCommand.java +++ b/src/main/java/net/pterodactylus/sone/fcp/GetLocalSonesCommand.java @@ -1,5 +1,5 @@ /* - * Sone - GetLocalSonesCommand.java - Copyright © 2011–2012 David Roden + * Sone - GetLocalSonesCommand.java - Copyright © 2011–2020 David Roden * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -17,16 +17,14 @@ package net.pterodactylus.sone.fcp; +import static net.pterodactylus.sone.fcp.AbstractSoneCommandKt.encodeSones; + import net.pterodactylus.sone.core.Core; -import net.pterodactylus.sone.freenet.fcp.FcpException; import freenet.support.SimpleFieldSet; -import freenet.support.api.Bucket; /** * Implements the “GetLocalSones” FCP command that returns the list of local * Sones to the sender. - * - * @author David ‘Bombe’ Roden */ public class GetLocalSonesCommand extends AbstractSoneCommand { @@ -44,7 +42,7 @@ public class GetLocalSonesCommand extends AbstractSoneCommand { * {@inheritDoc} */ @Override - public Response execute(SimpleFieldSet parameters, Bucket data, AccessType accessType) throws FcpException { + public Response execute(SimpleFieldSet parameters) { return new Response("ListLocalSones", encodeSones(getCore().getLocalSones(), "LocalSones.")); }