Clippy
This commit is contained in:
@@ -12,7 +12,7 @@ pub struct Reject(pub Actor);
|
||||
|
||||
impl Reject {
|
||||
async fn perform(self, state: JobState) -> Result<(), anyhow::Error> {
|
||||
if let Some(_) = state.actors.unfollower(&self.0).await? {
|
||||
if state.actors.unfollower(&self.0).await?.is_some() {
|
||||
state.db.remove_listener(self.0.inbox.clone()).await?;
|
||||
}
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ impl Undo {
|
||||
async fn perform(self, state: JobState) -> Result<(), anyhow::Error> {
|
||||
let was_following = state.actors.is_following(&self.actor.id).await;
|
||||
|
||||
if let Some(_) = state.actors.unfollower(&self.actor).await? {
|
||||
if state.actors.unfollower(&self.actor).await?.is_some() {
|
||||
state.db.remove_listener(self.actor.inbox.clone()).await?;
|
||||
}
|
||||
|
||||
|
||||
@@ -110,8 +110,8 @@ impl<T> MaybeSupported<T> {
|
||||
struct SupportedVersion(String);
|
||||
struct SupportedNodeinfo(String);
|
||||
|
||||
static SUPPORTED_VERSIONS: &'static str = "2.";
|
||||
static SUPPORTED_NODEINFO: &'static str = "http://nodeinfo.diaspora.software/ns/schema/2.";
|
||||
static SUPPORTED_VERSIONS: &str = "2.";
|
||||
static SUPPORTED_NODEINFO: &str = "http://nodeinfo.diaspora.software/ns/schema/2.";
|
||||
|
||||
struct SupportedVersionVisitor;
|
||||
struct SupportedNodeinfoVisitor;
|
||||
|
||||
Reference in New Issue
Block a user