use crate::bootstrap::state::AppState;
use shared::Response as RpResponse;
pub async fn handle(state: AppState) -> RpResponse {
match crate::store::projects::list(&state.db).await {
Ok(ps) => RpResponse::Projects(ps),
Err(e) => RpResponse::err("DatabaseError", e.to_string()),
}
}