diff --git a/ee/tabby-db/migrations/0022_github-provider.down.sql b/ee/tabby-db/migrations/0022_github-provider.down.sql index 2ada5c2aaf31..2af049ced3da 100644 --- a/ee/tabby-db/migrations/0022_github-provider.down.sql +++ b/ee/tabby-db/migrations/0022_github-provider.down.sql @@ -1,2 +1 @@ DROP TABLE github_repository_provider; -DROP TABLE github_provided_repositories; diff --git a/ee/tabby-webserver/src/repositories/mod.rs b/ee/tabby-webserver/src/repositories/mod.rs index 2387bf1697e2..82dcf3aec578 100644 --- a/ee/tabby-webserver/src/repositories/mod.rs +++ b/ee/tabby-webserver/src/repositories/mod.rs @@ -7,6 +7,7 @@ use anyhow::Result; use axum::{ extract::{Path, State}, http::StatusCode, + middleware::from_fn_with_state, response::Response, routing, Json, Router, }; @@ -14,6 +15,7 @@ pub use resolve::RepositoryCache; use tracing::{instrument, warn}; use crate::{ + handler::require_login_middleware, repositories::resolve::{RepositoryMeta, ResolveParams}, schema::{ auth::AuthenticationService, github_repository_provider::GithubRepositoryProviderService, @@ -47,7 +49,7 @@ pub fn routes( .with_state(rs.clone()) .nest("/oauth", oauth::routes(oauth_state)) .fallback(not_found) - // .layer(from_fn_with_state(auth, require_login_middleware)) + .layer(from_fn_with_state(auth, require_login_middleware)) } async fn not_found() -> StatusCode {