fix clippy warnings

pull/35/head
Takayuki Maeda 3 years ago
parent cbd33b1659
commit e1ae7d0f9a

@ -31,11 +31,7 @@ impl Pool for MySqlPool {
for db in databases {
list.push(Database::new(
db.clone(),
self.get_tables(db.clone())
.await?
.into_iter()
.map(|table| table.into())
.collect(),
self.get_tables(db.clone()).await?,
))
}
Ok(list)

@ -85,7 +85,7 @@ impl Pool for PostgresPool {
database = database.name,
table = table.name,
filter = filter,
table_schema = table.schema.clone().unwrap_or("public".to_string()),
table_schema = table.schema.clone().unwrap_or_else(|| "public".to_string()),
page = page,
limit = RECORDS_LIMIT_PER_PAGE
)
@ -94,7 +94,7 @@ impl Pool for PostgresPool {
r#"SELECT * FROM "{database}"."{table_schema}"."{table}" limit {limit} offset {page}"#,
database = database.name,
table = table.name,
table_schema = table.schema.clone().unwrap_or("public".to_string()),
table_schema = table.schema.clone().unwrap_or_else(|| "public".to_string()),
page = page,
limit = RECORDS_LIMIT_PER_PAGE
)

Loading…
Cancel
Save