Skip to content

Commit

Permalink
fix clippy
Browse files Browse the repository at this point in the history
Signed-off-by: simonsan <[email protected]>
  • Loading branch information
simonsan committed Mar 30, 2024
1 parent e73d00f commit c33a60f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion crates/storage/src/entity/activities.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#![allow(unused_qualifications)]
//! `SeaORM` Entity. Generated by sea-orm-codegen 0.12.15
use chrono::{DateTime, FixedOffset};
use sea_orm::entity::prelude::*;

#[derive(Clone, Debug, PartialEq, DeriveEntityModel, Eq)]
#[sea_orm(table_name = "activities")]
pub struct Model {
Expand Down
13 changes: 7 additions & 6 deletions crates/storage/src/storage/sqlite.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
use std::{collections::BTreeMap, fs::File, path::PathBuf};

use itertools::Itertools;
use sea_orm::{Database, DatabaseConnection, EntityTrait, ModelTrait, QueryFilter};
use tokio::runtime::Runtime;
// use itertools::Itertools;
use sea_orm::{Database, DatabaseConnection, EntityTrait, ModelTrait};
use tracing::debug;

use pace_core::{
Expand All @@ -20,7 +19,7 @@ use pace_error::{DatabaseStorageErrorKind, PaceOptResult, PaceResult};
use pace_time::{date::PaceDate, duration::PaceDurationRange, time_range::TimeRangeOptions};

use crate::{
entity::{activities, activity_status, descriptions, prelude::Activities, tags},
entity::{descriptions, prelude::Activities},
migration::{Migrator, MigratorTrait},
runtime,
};
Expand Down Expand Up @@ -124,12 +123,14 @@ impl ActivityReadOps for DatabaseActivityStorage {
.into());

Check warning on line 123 in crates/storage/src/storage/sqlite.rs

View check run for this annotation

Codecov / codecov/patch

crates/storage/src/storage/sqlite.rs#L123

Added line #L123 was not covered by tests
};

let description = activity
let _description = activity
.find_related(descriptions::Entity)
.one(&self.connection)
.await;

Check warning on line 129 in crates/storage/src/storage/sqlite.rs

View check run for this annotation

Codecov / codecov/patch

crates/storage/src/storage/sqlite.rs#L126-L129

Added lines #L126 - L129 were not covered by tests

Ok(ActivityItem::default())
todo!("implement read_activity for sqlite");

Check warning on line 131 in crates/storage/src/storage/sqlite.rs

View check run for this annotation

Codecov / codecov/patch

crates/storage/src/storage/sqlite.rs#L131

Added line #L131 was not covered by tests

// Ok(ActivityItem::default())
})
}

Expand Down

0 comments on commit c33a60f

Please sign in to comment.