According to the documentation on this API, publishing a message should always be accompanied by un-publishing the same message because the nearby API can be very battery intensive. I added a call to that method as shown in the linked documentation.
I've never done any development for cordova plugins, so I don't know how to test this. I just copied the format from your other methods, and I assume it should work. Please test this before accepting it, because I don't know how.
According to the documentation on this API, publishing a message should always be accompanied by un-publishing the same message because the nearby API can be very battery intensive. I added a call to that method as shown in the linked documentation.
I've never done any development for cordova plugins, so I don't know how to test this. I just copied the format from your other methods, and I assume it should work. Please test this before accepting it, because I don't know how.