Show commit details above changed files
This commit is contained in:
@@ -189,22 +189,17 @@ impl Client {
|
||||
})
|
||||
}
|
||||
|
||||
pub async fn commit_files(
|
||||
&self,
|
||||
repository: &RepositoryId,
|
||||
sha: &str,
|
||||
) -> Result<Vec<models::CommitAffectedFiles>> {
|
||||
pub async fn commit(&self, repository: &RepositoryId, sha: &str) -> Result<models::Commit> {
|
||||
apis::repository_api::repo_get_single_commit(
|
||||
&self.configuration(),
|
||||
&repository.owner,
|
||||
&repository.repository,
|
||||
sha,
|
||||
Some(false),
|
||||
Some(true),
|
||||
None,
|
||||
Some(true),
|
||||
)
|
||||
.await
|
||||
.map(|commit| commit.files.unwrap_or_default())
|
||||
.map_err(Error::generated)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user