I'd do a `unregisterThread` too, to speed up the thread deletion process (instead of using indexOf + splice, which is fine for deleting one message, but not a whole thread)