mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-12-28 20:15:20 +03:00
Optionally, skip the validation when getting the project
Add flag to enable getting the project information from the storage without performing the validation
This commit is contained in:
parent
2c6f295cc5
commit
c1cd40a811
@ -33,8 +33,13 @@ pub mod commands {
|
||||
pub fn get_project(
|
||||
projects: State<'_, Controller>,
|
||||
id: ProjectId,
|
||||
no_validation: Option<bool>,
|
||||
) -> Result<projects::Project, Error> {
|
||||
Ok(projects.get_validated(id)?)
|
||||
if no_validation.unwrap_or(false) {
|
||||
Ok(projects.get(id)?)
|
||||
} else {
|
||||
Ok(projects.get_validated(id)?)
|
||||
}
|
||||
}
|
||||
|
||||
#[tauri::command(async)]
|
||||
|
Loading…
Reference in New Issue
Block a user