diff --git a/src/main/java/io/github/norbipeti/gcdc/controller/DCController.java b/src/main/java/io/github/norbipeti/gcdc/controller/DCController.java
index b17cd4e..4e603dd 100644
--- a/src/main/java/io/github/norbipeti/gcdc/controller/DCController.java
+++ b/src/main/java/io/github/norbipeti/gcdc/controller/DCController.java
@@ -50,7 +50,7 @@ public class DCController {
service.deleteSession(user);
String token = UUID.randomUUID().toString();
service.insertSession(new Session(token, Snowflake.of(channel), user));
- return "Run the following command:
\ndcsetup \"" + token + "\"";
+ return "Run the following command:
\ndcsetup \"" + token + "\"\n
Then you can close this window.";
}
@GetMapping("/api/users/get")
diff --git a/src/main/java/io/github/norbipeti/gcdc/service/DiscordService.java b/src/main/java/io/github/norbipeti/gcdc/service/DiscordService.java
index f222fae..1445276 100644
--- a/src/main/java/io/github/norbipeti/gcdc/service/DiscordService.java
+++ b/src/main/java/io/github/norbipeti/gcdc/service/DiscordService.java
@@ -6,7 +6,6 @@ import discord4j.core.event.domain.message.MessageCreateEvent;
import discord4j.core.object.entity.GuildMessageChannel;
import discord4j.core.object.entity.Member;
import discord4j.core.object.util.Snowflake;
-import io.github.norbipeti.gcdc.Application;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;
import org.springframework.web.context.request.async.DeferredResult;
@@ -43,9 +42,9 @@ public class DiscordService {
client.getChannelById(Snowflake.of(channel)).cast(GuildMessageChannel.class)
.flatMap(ch -> getUsername(user, ch)
.flatMap(name -> ch.createEmbed(ecs -> ecs.setAuthor(name, null, null)
- .setColor(Color.BLUE).setDescription(message))))
+ .setColor(Color.BLUE).setDescription(message)).map(msg -> name)))
.doOnError(result::setErrorResult)
- .subscribe(msg -> result.setResult(Application.RESULT_OK));
+ .subscribe(name -> result.setResult(Map.of("response", "OK", "username", name)));
return result;
}