X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Ffcp%2FGetSoneCommand.java;h=64d24febd037f2142ee996ade9849c44895e5542;hp=d0bd5ccd2e8fa893527fb56e14d699ff412407ed;hb=faf66247a34f64946990a985d2ea3003465969cb;hpb=914d5522692e7714ba5bdefb002fedc8e293f5fc diff --git a/src/main/java/net/pterodactylus/sone/fcp/GetSoneCommand.java b/src/main/java/net/pterodactylus/sone/fcp/GetSoneCommand.java index d0bd5cc..64d24fe 100644 --- a/src/main/java/net/pterodactylus/sone/fcp/GetSoneCommand.java +++ b/src/main/java/net/pterodactylus/sone/fcp/GetSoneCommand.java @@ -1,5 +1,5 @@ /* - * Sone - GetSoneCommand.java - Copyright © 2011–2016 David Roden + * Sone - GetSoneCommand.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,6 +17,8 @@ package net.pterodactylus.sone.fcp; +import static net.pterodactylus.sone.fcp.AbstractSoneCommandKt.encodeSone; + import net.pterodactylus.sone.core.Core; import net.pterodactylus.sone.data.Profile; import net.pterodactylus.sone.data.Sone; @@ -29,8 +31,6 @@ import freenet.support.SimpleFieldSet; /** * Implements the “GetSone“ FCP command which returns {@link Profile} * information about a {@link Sone}. - * - * @author David ‘Bombe’ Roden */ public class GetSoneCommand extends AbstractSoneCommand { @@ -50,8 +50,8 @@ public class GetSoneCommand extends AbstractSoneCommand { @Override public Response execute(SimpleFieldSet parameters) throws FcpException { Sone sone = getSone(parameters, "Sone", false); - Optional localSone = getSone(parameters, "LocalSone", false, false); - return new Response("Sone", encodeSone(sone, "", localSone)); + Optional localSone = getSone(parameters, "LocalSone", true, false); + return new Response("Sone", encodeSone(sone, "Sone.", localSone)); } }