diff --git a/src/components/contacts/ContactDropDownMenu.vue b/src/components/contacts/ContactDropDownMenu.vue index 803590e..6025ab2 100644 --- a/src/components/contacts/ContactDropDownMenu.vue +++ b/src/components/contacts/ContactDropDownMenu.vue @@ -14,6 +14,14 @@
{{ contact.advName }}
+ + + + + + Reset Path + + @@ -46,6 +54,13 @@ export default { "contact-deleted", ], methods: { + async onResetPath(contact) { + + // reset path + await Connection.resetContactPath(contact.publicKey); + await Connection.loadContacts(); + + }, async onDeleteContact(contact) { // confirm user wants to remove this contact diff --git a/src/js/Connection.js b/src/js/Connection.js index c2ea657..10e7eac 100644 --- a/src/js/Connection.js +++ b/src/js/Connection.js @@ -65,6 +65,10 @@ class Connection { await GlobalState.connection.sendCommandSetDeviceTime(timestamp); } + static async resetContactPath(publicKey) { + await GlobalState.connection.sendCommandResetPath(publicKey); + } + static async removeContact(publicKey) { await GlobalState.connection.sendCommandRemoveContact(publicKey); }