From 85aafb4b967925795dbf0932c13c97151b47e46f Mon Sep 17 00:00:00 2001 From: realaravinth Date: Sun, 1 May 2022 19:07:49 +0530 Subject: [PATCH] feat: add repository_exists method --- db/db-core/src/lib.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/db/db-core/src/lib.rs b/db/db-core/src/lib.rs index 70ccbb5..f18df2b 100644 --- a/db/db-core/src/lib.rs +++ b/db/db-core/src/lib.rs @@ -112,6 +112,9 @@ pub trait SCDatabase: std::marker::Send + std::marker::Sync + CloneSPDatabase { /// check if an user exists. When hostname of a forge instace is provided, username search is /// done only on that forge async fn user_exists(&self, username: &str, hostname: Option<&str>) -> DBResult; + + /// check if a repository exists. + async fn repository_exists(&self, name: &str, owner: &str, hostname: &str) -> DBResult; } /// Trait to clone SCDatabase