mirror of
https://github.com/chatmail/core.git
synced 2026-04-01 21:12:13 +03:00
Add two TODOs, and remove two
This commit is contained in:
@@ -827,6 +827,7 @@ impl Context {
|
||||
"UPDATE config SET value=? WHERE keyname='configured_addr'",
|
||||
(addr,),
|
||||
)?;
|
||||
// TODO set as published
|
||||
|
||||
// Update the timestamp for the primary transport
|
||||
// so it becomes the first in `get_all_self_addrs()` list
|
||||
@@ -975,7 +976,7 @@ impl Context {
|
||||
}
|
||||
|
||||
/// Returns all published self addresses, newest first.
|
||||
/// See TODO API
|
||||
/// See `[Context::set_transport_unpublished]`
|
||||
pub(crate) async fn get_published_self_addrs(&self) -> Result<Vec<String>> {
|
||||
self.sql
|
||||
.query_map_vec(
|
||||
@@ -999,7 +1000,7 @@ impl Context {
|
||||
}
|
||||
|
||||
/// Returns all published secondary self addresses.
|
||||
/// See TODO API
|
||||
/// See `[Context::set_transport_unpublished]`
|
||||
pub(crate) async fn get_published_secondary_self_addrs(&self) -> Result<Vec<String>> {
|
||||
self.sql
|
||||
.query_map_vec(
|
||||
|
||||
@@ -273,6 +273,7 @@ impl Context {
|
||||
/// existing secondary transports are set to unpublished,
|
||||
/// so that an existing transport address doesn't suddenly get spammed with a lot of messages.
|
||||
pub async fn set_transport_unpublished(&self, addr: &str, unpublished: bool) -> Result<()> {
|
||||
// TODO check if this is the primary transport
|
||||
self.sql
|
||||
.execute(
|
||||
"UPDATE transports SET is_published=? WHERE addr=?",
|
||||
|
||||
Reference in New Issue
Block a user