date-override: cargo fmt

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Cameron Cordes
2026-05-09 21:23:11 -04:00
parent 108bbeb029
commit 9871c685b4

View File

@@ -752,9 +752,7 @@ fn locate_image_exif_row(
.filter(rel_path.eq(&normalized).or(rel_path.eq(&windows_form)))
.first::<ImageExif>(connection)
.map_err(|e| match e {
diesel::result::Error::NotFound => {
anyhow::Error::msg("row_not_found")
}
diesel::result::Error::NotFound => anyhow::Error::msg("row_not_found"),
other => anyhow::Error::from(other).context("lookup_failed"),
})
}
@@ -1322,11 +1320,8 @@ impl ExifDao for SqliteExifDao {
// Read-modify-write under the dao mutex so the snapshot is
// consistent with the value being overwritten. The mutex holds
// for the duration of this closure — no other writer can race.
let current = locate_image_exif_row(
connection.deref_mut(),
library_id_val,
rel_path_val,
)?;
let current =
locate_image_exif_row(connection.deref_mut(), library_id_val, rel_path_val)?;
// Snapshot only on first override. Subsequent overrides keep
// the original snapshot intact so a single revert restores
@@ -1380,11 +1375,8 @@ impl ExifDao for SqliteExifDao {
let mut connection = self.connection.lock().expect("Unable to get ExifDao");
let current = locate_image_exif_row(
connection.deref_mut(),
library_id_val,
rel_path_val,
)?;
let current =
locate_image_exif_row(connection.deref_mut(), library_id_val, rel_path_val)?;
// No override active — nothing to revert. Return the current
// row unchanged so the endpoint is idempotent.