1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-12-04 14:46:46 -05:00

Added HAVE_LIBGPGME check for setting account key

This commit is contained in:
James Booth 2015-08-25 20:35:45 +01:00
parent f6a91145b6
commit 872ab8e529

View File

@ -486,12 +486,16 @@ cmd_account(ProfWin *window, const char * const command, gchar **args)
}
cons_show("");
} else if (strcmp(property, "pgpkeyid") == 0) {
#ifdef HAVE_LIBGPGME
if (!p_gpg_valid_key(value)) {
cons_show("Invalid PGP key ID specified, see /pgp keys");
} else {
accounts_set_pgp_keyid(account_name, value);
cons_show("Updated PGP key ID for account %s: %s", account_name, value);
}
#else
cons_show("PGP support is not included in this build.");
#endif
cons_show("");
} else if (valid_resource_presence_string(property)) {
int intval;