mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-09-11 21:53:02 +02:00
fix warnings and errors when building with no features
Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
parent
f761d4d5c9
commit
ef2d307c15
3 changed files with 51 additions and 55 deletions
|
@ -13,7 +13,7 @@ use conduwuit::{
|
|||
warn, Config, Result,
|
||||
};
|
||||
|
||||
use crate::{migrations, Services};
|
||||
use crate::Services;
|
||||
|
||||
/// Migrates a media directory from legacy base64 file names to sha2 file names.
|
||||
/// All errors are fatal. Upon success the database is keyed to not perform this
|
||||
|
@ -48,12 +48,6 @@ pub(crate) async fn migrate_sha256_media(services: &Services) -> Result<()> {
|
|||
}
|
||||
}
|
||||
|
||||
// Apply fix from when sha256_media was backward-incompat and bumped the schema
|
||||
// version from 13 to 14. For users satisfying these conditions we can go back.
|
||||
if services.globals.db.database_version().await == 14 && migrations::DATABASE_VERSION == 13 {
|
||||
services.globals.db.bump_database_version(13)?;
|
||||
}
|
||||
|
||||
db["global"].insert(b"feat_sha256_media", []);
|
||||
info!("Finished applying sha256_media");
|
||||
Ok(())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue