Explorar o código

Fix rust-lang/rust filters on commits and milestone handlers

Previously we would make an attempt if at least one of the organization or
repository was "rust-lang" or "rust", respectively.
Mark Rousskov %!s(int64=4) %!d(string=hai) anos
pai
achega
34c01cb520
Modificáronse 2 ficheiros con 2 adicións e 2 borrados
  1. 1 1
      src/handlers/milestone_prs.rs
  2. 1 1
      src/handlers/rustc_commits.rs

+ 1 - 1
src/handlers/milestone_prs.rs

@@ -18,7 +18,7 @@ pub async fn handle(ctx: &Context, event: &Event) -> anyhow::Result<()> {
     }
 
     let repo = e.issue.repository();
-    if repo.organization != "rust-lang" && repo.repository != "rust" {
+    if !(repo.organization == "rust-lang" && repo.repository == "rust") {
         return Ok(());
     }
 

+ 1 - 1
src/handlers/rustc_commits.rs

@@ -34,7 +34,7 @@ pub async fn handle(ctx: &Context, event: &Event) -> anyhow::Result<()> {
     }
 
     let repo = event.issue.repository();
-    if repo.organization != "rust-lang" && repo.repository != "rust" {
+    if !(repo.organization == "rust-lang" && repo.repository == "rust") {
         return Ok(());
     }