Update.
This commit is contained in:
parent
4a6bba7734
commit
fd5d1c3401
src/snek
@ -146,7 +146,7 @@ class ChatInputComponent extends NjetComponent {
|
||||
this.user = user;
|
||||
});
|
||||
|
||||
this.liveType = this.getAttribute("live-type") === "true";
|
||||
this.liveType = this.getAttribute("live-type") !== "true";
|
||||
this.liveTypeInterval = parseInt(this.getAttribute("live-type-interval")) || 6;
|
||||
this.channelUid = this.getAttribute("channel");
|
||||
|
||||
|
@ -270,10 +270,11 @@ class RPCView(BaseView):
|
||||
async def send_message(self, channel_uid, message, is_final=True):
|
||||
self._require_login()
|
||||
|
||||
if not is_final:
|
||||
check_message = await self.services.channel_message.get(channel_uid=channel_uid, user_uid=self.user_uid,is_final=False)
|
||||
if check_message:
|
||||
return await self.update_message_text(check_message["uid"], message)
|
||||
#if not is_final:
|
||||
# check_message = await self.services.channel_message.get(channel_uid=channel_uid, user_uid=self.user_uid,is_final=False)
|
||||
# if check_message:
|
||||
# return await self.update_message_text(check_message["uid"], message)
|
||||
is_final = True
|
||||
message = await self.services.chat.send(
|
||||
self.user_uid, channel_uid, message, is_final
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user