创建频道和机器人时,不再设置默认头像
This commit is contained in:
@@ -48,10 +48,6 @@ public class CreateChatroomAction extends AdminAction {
|
|||||||
inputCreateChatroom.setChatroomId(messagesStore.getShortUUID());
|
inputCreateChatroom.setChatroomId(messagesStore.getShortUUID());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (inputCreateChatroom.getPortrait() == null || inputCreateChatroom.getPortrait().length() == 0) {
|
|
||||||
inputCreateChatroom.setPortrait("https://avatars.io/gravatar/" + inputCreateChatroom.getChatroomId());
|
|
||||||
}
|
|
||||||
|
|
||||||
WFCMessage.ChatroomInfo info = inputCreateChatroom.toChatroomInfo();
|
WFCMessage.ChatroomInfo info = inputCreateChatroom.toChatroomInfo();
|
||||||
messagesStore.createChatroom(inputCreateChatroom.getChatroomId(), info);
|
messagesStore.createChatroom(inputCreateChatroom.getChatroomId(), info);
|
||||||
setResponseContent(RestResult.ok(new OutputCreateChatroom(inputCreateChatroom.getChatroomId())), response);
|
setResponseContent(RestResult.ok(new OutputCreateChatroom(inputCreateChatroom.getChatroomId())), response);
|
||||||
|
|||||||
@@ -49,10 +49,6 @@ public class CreateRobotAction extends AdminAction {
|
|||||||
inputCreateRobot.setUserId(messagesStore.getShortUUID());
|
inputCreateRobot.setUserId(messagesStore.getShortUUID());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (inputCreateRobot.getPortrait() == null || inputCreateRobot.getPortrait().length() == 0) {
|
|
||||||
inputCreateRobot.setPortrait("https://avatars.io/gravatar/" + inputCreateRobot.getUserId());
|
|
||||||
}
|
|
||||||
|
|
||||||
WFCMessage.User newUser = inputCreateRobot.toUser();
|
WFCMessage.User newUser = inputCreateRobot.toUser();
|
||||||
try {
|
try {
|
||||||
messagesStore.addUserInfo(newUser);
|
messagesStore.addUserInfo(newUser);
|
||||||
|
|||||||
Reference in New Issue
Block a user