use super::super::models::GitBranchStats;
use super::super::RepositoriesClient;
use crate::constants;
use crate::constants::ApiPath;
use crate::error::Result;
impl RepositoriesClient<'_> {
pub async fn get_branch(&self, id: &str, name: &str) -> Result<GitBranchStats> {
let qp = vec![(constants::query::NAME.into(), name.into())];
self.http
.get(
&ApiPath::repository_branches(id),
&crate::util::ref_query(&qp),
)
.await
}
}