mirror of
https://codeberg.org/tyy/aspm
synced 2024-12-22 20:39:29 -07:00
Fix a few clippy recommendations
This commit is contained in:
parent
43851d1f98
commit
91a4a42fe6
2 changed files with 2 additions and 2 deletions
|
@ -261,7 +261,7 @@ impl AspmSubcommand for KeysImportGpgCommand {
|
|||
};
|
||||
// Because GPGME's context object is not 'Send', normal .await can't be used here, so this just blocks as a workaround
|
||||
let res = runtime
|
||||
.block_on(async { keys::Entity::insert(entry).exec(&state.db).await })
|
||||
.block_on(keys::Entity::insert(entry).exec(&state.db))
|
||||
.context("Unable to add key to database")?;
|
||||
if res.last_insert_id != asp_key.fingerprint {
|
||||
bail!("The key was unable to be saved to the database")
|
||||
|
|
|
@ -13,7 +13,7 @@ pub trait AspmSubcommand: Parser + Sync {
|
|||
panic!("Not implemented")
|
||||
}
|
||||
fn execute_sync(&self, state: AspmState, runtime: Runtime) -> Result<(), anyhow::Error> {
|
||||
runtime.block_on(async { self.execute(state).await })
|
||||
runtime.block_on(self.execute(state))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue