Folder names (#318)

This commit is contained in:
Wyatt Verchere
2023-07-21 20:16:07 -07:00
committed by GitHub
parent 4941260805
commit 3fa33dc241
42 changed files with 1129 additions and 535 deletions

View File

@@ -50,7 +50,18 @@ pub async fn logs_get_output_by_datetime(
profile_uuid: Uuid,
datetime_string: String,
) -> Result<String> {
Ok(logs::get_output_by_datetime(profile_uuid, &datetime_string).await?)
let profile_path = if let Some(p) =
crate::profile::get_by_uuid(profile_uuid, None).await?
{
p.profile_id()
} else {
return Err(theseus::Error::from(
theseus::ErrorKind::UnmanagedProfileError(profile_uuid.to_string()),
)
.into());
};
Ok(logs::get_output_by_datetime(&profile_path, &datetime_string).await?)
}
/// Delete all logs for a profile by profile id