Przeglądaj źródła

hosts: enable the transition from Refine to Move

We need to be able to move hosts after refining them, whether that's to
send them to the greylist or to the whitelist.
draoi 2 lat temu
rodzic
commit
ab52d14372
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      src/net/hosts.rs

+ 1 - 1
src/net/hosts.rs

@@ -226,7 +226,7 @@ impl HostState {
         let end = HostState::Move.to_string();
         let end = HostState::Move.to_string();
         match self {
         match self {
             HostState::Insert => Err(Error::HostStateBlocked(start, end)),
             HostState::Insert => Err(Error::HostStateBlocked(start, end)),
-            HostState::Refine => Err(Error::HostStateBlocked(start, end)),
+            HostState::Refine => Ok(HostState::Move),
             HostState::Connect => Ok(HostState::Move),
             HostState::Connect => Ok(HostState::Move),
             HostState::Suspend => Err(Error::HostStateBlocked(start, end)),
             HostState::Suspend => Err(Error::HostStateBlocked(start, end)),
             HostState::Connected(_) => Ok(HostState::Move),
             HostState::Connected(_) => Ok(HostState::Move),