Skip to content

Commit

Permalink
fmt the code
Browse files Browse the repository at this point in the history
  • Loading branch information
wangkirin committed Mar 20, 2024
1 parent fa2b5be commit 3aefa13
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/assets.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use crate::prelude::*;
use mime:: Mime;
use mime::Mime;
use serde::Serialize;
use std::borrow::Cow;
use std::collections::HashMap;
Expand Down
6 changes: 2 additions & 4 deletions src/db/migrations.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
use crate::prelude::*;
use rand::{
distributions::{Alphanumeric, DistString},
};
use rand::distributions::{Alphanumeric, DistString};
use rusqlite::{Connection, Transaction};
use std::collections::HashSet;

Expand Down Expand Up @@ -387,7 +385,7 @@ pub fn execute(db: &mut Connection) -> Fallible<()> {
};

for &(name, ref migration) in &migrations() {
if !executed_migrations.contains(&name.to_string()) {
if !executed_migrations.contains(name) {
let t = db.transaction()?;
match migration {
MigrationKind::SQL(sql) => t.execute_batch(sql),
Expand Down
1 change: 0 additions & 1 deletion src/utils/serialize.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
use serde::ser::{Serialize, SerializeSeq, Serializer};


pub fn to_vec<S, T>(data: T, serializer: S) -> Result<S::Ok, S::Error>
where
S: Serializer,
Expand Down

0 comments on commit 3aefa13

Please sign in to comment.