src/twc-profile.c
This commit is contained in:
parent
1a18e112a7
commit
1941bdcd64
1 changed files with 21 additions and 13 deletions
|
@ -575,7 +575,15 @@ twc_profile_set_online_status(struct t_twc_profile *profile, bool status)
|
||||||
if (!(profile)) {
|
if (!(profile)) {
|
||||||
weechat_printf(profile->buffer, "%sno profile",
|
weechat_printf(profile->buffer, "%sno profile",
|
||||||
weechat_prefix("network"));
|
weechat_prefix("network"));
|
||||||
} else if (profile->tox_online ^ status) {
|
return;
|
||||||
|
}
|
||||||
|
/* failsafe - called while exiting! */
|
||||||
|
if (!(profile->tox)) {
|
||||||
|
weechat_printf(profile->buffer, "%sno tox",
|
||||||
|
weechat_prefix("network"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (profile->tox_online ^ status) {
|
||||||
TOX_CONNECTION connection = tox_self_get_connection_status(profile->tox);
|
TOX_CONNECTION connection = tox_self_get_connection_status(profile->tox);
|
||||||
|
|
||||||
profile->tox_online = status;
|
profile->tox_online = status;
|
||||||
|
|
Loading…
Reference in a new issue