forked from CringeStudios/gamja
Add support for account-notify
This commit is contained in:
parent
8e631f97ef
commit
d12e1109b3
@ -798,6 +798,8 @@ export default class App extends Component {
|
|||||||
case irc.RPL_MONOFFLINE:
|
case irc.RPL_MONOFFLINE:
|
||||||
case "AWAY":
|
case "AWAY":
|
||||||
case "SETNAME":
|
case "SETNAME":
|
||||||
|
case "CHGHOST":
|
||||||
|
case "ACCOUNT":
|
||||||
case "CAP":
|
case "CAP":
|
||||||
case "AUTHENTICATE":
|
case "AUTHENTICATE":
|
||||||
case "PING":
|
case "PING":
|
||||||
|
@ -3,6 +3,7 @@ import * as irc from "./irc.js";
|
|||||||
// Static list of capabilities that are always requested when supported by the
|
// Static list of capabilities that are always requested when supported by the
|
||||||
// server
|
// server
|
||||||
const permanentCaps = [
|
const permanentCaps = [
|
||||||
|
"account-notify",
|
||||||
"away-notify",
|
"away-notify",
|
||||||
"batch",
|
"batch",
|
||||||
"chghost",
|
"chghost",
|
||||||
|
6
state.js
6
state.js
@ -464,6 +464,12 @@ export const State = {
|
|||||||
username: msg.params[0],
|
username: msg.params[0],
|
||||||
hostname: msg.params[1],
|
hostname: msg.params[1],
|
||||||
});
|
});
|
||||||
|
case "ACCOUNT":
|
||||||
|
let account = msg.params[0];
|
||||||
|
if (account === "*") {
|
||||||
|
account = null;
|
||||||
|
}
|
||||||
|
return updateUser(msg.prefix.name, { account });
|
||||||
case "AWAY":
|
case "AWAY":
|
||||||
let awayMessage = msg.params[0];
|
let awayMessage = msg.params[0];
|
||||||
return updateUser(msg.prefix.name, { away: !!awayMessage });
|
return updateUser(msg.prefix.name, { away: !!awayMessage });
|
||||||
|
Loading…
x
Reference in New Issue
Block a user