diff options
| author | Conrad Ludgate <conradludgate@gmail.com> | 2021-02-15 09:07:49 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-02-15 09:07:49 +0000 |
| commit | 68c5ca9ecedb6001c61e933f2b7069c2e677213d (patch) | |
| tree | ca04351dd4309e77b1091f9a7ce10a7b4ae10ade /src/command/mod.rs | |
| parent | Update README.md (diff) | |
| download | atuin-68c5ca9ecedb6001c61e933f2b7069c2e677213d.zip | |
use database trait instead of sqlite impl (#10)
small improvements
Diffstat (limited to 'src/command/mod.rs')
| -rw-r--r-- | src/command/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/command/mod.rs b/src/command/mod.rs index a5dd039e..78e55a0d 100644 --- a/src/command/mod.rs +++ b/src/command/mod.rs @@ -2,7 +2,7 @@ use eyre::Result; use structopt::StructOpt; use uuid::Uuid; -use crate::local::database::Sqlite; +use crate::local::database::Database; mod history; mod import; @@ -35,7 +35,7 @@ pub fn uuid_v4() -> String { } impl AtuinCmd { - pub fn run(self, db: &mut Sqlite) -> Result<()> { + pub fn run(self, db: &mut impl Database) -> Result<()> { match self { Self::History(history) => history.run(db), Self::Import(import) => import.run(db), |
