1
0
Fork 0
mirror of https://github.com/deltachat/deltachat-core.git synced 2025-10-05 02:29:28 +02:00

new function to cleanup contacts

This commit is contained in:
Ampli-fier 2018-02-14 22:41:41 +01:00
parent 3c10679094
commit ea8543ee8d
3 changed files with 40 additions and 6 deletions

View file

@ -378,6 +378,7 @@ char* mrmailbox_cmdline(mrmailbox_t* mailbox, const char* cmdline)
"addcontact [<name>] <addr>\n"
"contactinfo <contact-id>\n"
"delcontact <contact-id>\n"
"cleanupcontacts\n"
"======================================Misc.==\n"
"event <event-id to test>\n"
"fileinfo <file>\n"
@ -1022,6 +1023,10 @@ char* mrmailbox_cmdline(mrmailbox_t* mailbox, const char* cmdline)
ret = safe_strdup("ERROR: Argument <contact-id> missing.");
}
}
else if( strcmp(cmd, "cleanupcontacts")==0 )
{
ret = mrmailbox_cleanup_contacts(mailbox)? COMMAND_SUCCEEDED : COMMAND_FAILED;
}
/*******************************************************************************
* Misc.