diff options
author | James Booth <boothj5@gmail.com> | 2016-11-22 00:39:52 +0000 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2016-11-22 00:39:52 +0000 |
commit | e043029a5069a30e8a7154a07d46260bece6358c (patch) | |
tree | 8e5affaa094513ae5d9c8c0c082f20f57e83629c /src/config/accounts.c | |
parent | c441dbfa42e58796f87fdcbb02ee4aa19cca2469 (diff) | |
download | profani-tty-e043029a5069a30e8a7154a07d46260bece6358c.tar.gz |
Allow clearing account resource
issue #880
Diffstat (limited to 'src/config/accounts.c')
-rw-r--r-- | src/config/accounts.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/config/accounts.c b/src/config/accounts.c index 233a5aa8..7dc852ae 100644 --- a/src/config/accounts.c +++ b/src/config/accounts.c @@ -585,6 +585,15 @@ accounts_clear_muc(const char *const account_name) } void +accounts_clear_resource(const char *const account_name) +{ + if (accounts_account_exists(account_name)) { + g_key_file_remove_key(accounts, account_name, "resource", NULL); + _save_accounts(); + } +} + +void accounts_clear_otr(const char *const account_name) { if (accounts_account_exists(account_name)) { |