From 20e00c35794971d4e2eb9dca5e25c1883a51a441 Mon Sep 17 00:00:00 2001 From: Dmitriy Pleshevskiy Date: Sat, 24 Apr 2021 22:48:10 +0300 Subject: [PATCH] chore: fix clippy warnings --- migra-cli/src/database/clients/mysql.rs | 2 +- migra-cli/src/database/clients/postgres.rs | 2 +- migra-cli/src/database/connection.rs | 4 ++-- migra-cli/src/database/mod.rs | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/migra-cli/src/database/clients/mysql.rs b/migra-cli/src/database/clients/mysql.rs index da1f792..2f53aa5 100644 --- a/migra-cli/src/database/clients/mysql.rs +++ b/migra-cli/src/database/clients/mysql.rs @@ -25,7 +25,7 @@ impl DatabaseStatements for MySqlConnection { } } -impl SupportsTransactionalDDL for MySqlConnection {} +impl SupportsTransactionalDdl for MySqlConnection {} impl DatabaseConnection for MySqlConnection { fn batch_execute(&mut self, query: &str) -> StdResult<()> { diff --git a/migra-cli/src/database/clients/postgres.rs b/migra-cli/src/database/clients/postgres.rs index f6e03f7..23b53a4 100644 --- a/migra-cli/src/database/clients/postgres.rs +++ b/migra-cli/src/database/clients/postgres.rs @@ -23,7 +23,7 @@ impl DatabaseStatements for PostgresConnection { } } -impl SupportsTransactionalDDL for PostgresConnection { +impl SupportsTransactionalDdl for PostgresConnection { #[inline] fn supports_transactional_ddl(&self) -> bool { true diff --git a/migra-cli/src/database/connection.rs b/migra-cli/src/database/connection.rs index 5ec3f05..6fa68e4 100644 --- a/migra-cli/src/database/connection.rs +++ b/migra-cli/src/database/connection.rs @@ -13,14 +13,14 @@ pub trait DatabaseStatements { fn create_migration_table_stmt(&self) -> &'static str; } -pub trait SupportsTransactionalDDL { +pub trait SupportsTransactionalDdl { #[inline] fn supports_transactional_ddl(&self) -> bool { false } } -pub trait DatabaseConnection: DatabaseStatements + SupportsTransactionalDDL { +pub trait DatabaseConnection: DatabaseStatements + SupportsTransactionalDdl { fn batch_execute(&mut self, query: &str) -> StdResult<()>; fn execute<'b>(&mut self, query: &str, params: ToSqlParams<'b>) -> StdResult; diff --git a/migra-cli/src/database/mod.rs b/migra-cli/src/database/mod.rs index a6e3f79..2510dab 100644 --- a/migra-cli/src/database/mod.rs +++ b/migra-cli/src/database/mod.rs @@ -9,7 +9,7 @@ pub mod prelude { pub use super::adapter::{ToSql, ToSqlParams, TryFromSql}; pub use super::connection::{ AnyConnection, DatabaseConnection, DatabaseStatements, OpenDatabaseConnection, - SupportsTransactionalDDL, + SupportsTransactionalDdl, }; pub use super::migration::ManageMigration; pub use super::transaction::ManageTransaction;