1
0
mirror of https://github.com/profanity-im/profanity.git synced 2025-01-03 14:57:42 -05:00

Override global OTR policy with account OTR policy

This commit is contained in:
James Booth 2014-05-11 15:20:24 +01:00
parent e8d84abb46
commit 6a38d57a0a

View File

@ -519,6 +519,14 @@ _otr_get_their_fingerprint(const char * const recipient)
static char *
_otr_get_policy(const char * const recipient)
{
// check account setting
ProfAccount *account = accounts_get_account(jabber_get_account_name());
if (account->otr_policy != NULL) {
account_free(account);
return account->otr_policy;
}
account_free(account);
// check global setting
return prefs_get_string(PREF_OTR_POLICY);
}