From 4f22ef80902ad409ed55a99dc5133cc1250a0d03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sondre=20Lilleb=C3=B8=20Gundersen?= Date: Mon, 24 Jun 2024 21:50:55 +0200 Subject: [PATCH] fix: Correct oauth scope check --- src/client/client.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/client/client.rs b/src/client/client.rs index 6773ffd..1264f26 100644 --- a/src/client/client.rs +++ b/src/client/client.rs @@ -460,9 +460,9 @@ impl PackagesClient { .x_oauth_scopes .clone() .unwrap() - .contains("write:packages") + .contains("delete:packages") { - eprintln!("The token does not have the scopes needed. Tokens need `write:packages`. The scopes found were {}.", response_headers.x_oauth_scopes.unwrap_or("none".to_string())); + eprintln!("The token does not have the scopes needed. Tokens need `delete:packages`. The scopes found were {}.", response_headers.x_oauth_scopes.unwrap_or("none".to_string())); exit(1); } }