diff --git a/giterated-models/src/repository/operations.rs b/giterated-models/src/repository/operations.rs index 377da45..bb44eae 100644 --- a/giterated-models/src/repository/operations.rs +++ b/giterated-models/src/repository/operations.rs @@ -19,7 +19,11 @@ use super::{IssueLabel, Repository, RepositoryIssue, RepositoryTreeEntry, Reposi /// - User Authorization /// - Potential User permissions checks #[derive(Clone, Debug, Serialize, Deserialize)] -pub struct RepositoryInfoRequest; +pub struct RepositoryInfoRequest { + pub extra_metadata: bool, + pub rev: Option, + pub path: Option, +} impl GiteratedOperation for RepositoryInfoRequest { type Success = RepositoryView; @@ -88,9 +92,13 @@ impl GiteratedOperation for RepositoryFileInspectRequest { } impl Object<'_, Repository, B> { - pub async fn info(&mut self) -> Result> { - self.request::(RepositoryInfoRequest) - .await + pub async fn info(&mut self, extra_metadata: bool, rev: Option, path: Option) -> Result> { + self.request::(RepositoryInfoRequest { + extra_metadata, + rev, + path, + }) + .await } // pub async fn issues_count(&mut self) -> Result> { // self.request::(RepositoryIssuesCountRequest) diff --git a/giterated-models/src/user/settings.rs b/giterated-models/src/user/settings.rs index 0d4a4da..bb38c06 100644 --- a/giterated-models/src/user/settings.rs +++ b/giterated-models/src/user/settings.rs @@ -2,7 +2,7 @@ use serde::{Deserialize, Serialize}; use crate::settings::Setting; -#[derive(Debug, Serialize, Deserialize)] +#[derive(Debug, Serialize, Deserialize, Clone)] pub struct UserBio(pub String); impl Setting for UserBio { @@ -20,7 +20,7 @@ impl Setting for UserDisplayName { } } -#[derive(Debug, Serialize, Deserialize)] +#[derive(Debug, Serialize, Deserialize, Clone)] pub struct UserDisplayImage(pub String); impl Setting for UserDisplayImage {