Skip to content

Commit

Permalink
Merge branch 'master' into pr/2353
Browse files Browse the repository at this point in the history
  • Loading branch information
billy1624 committed Oct 4, 2024
2 parents 1df1216 + b3db9de commit 1cff03f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 12 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -239,12 +239,12 @@ jobs:
examples/basic,
examples/graphql_example,
examples/jsonrpsee_example,
examples/loco_example,
examples/loco_starter,
examples/loco_seaography,
# examples/loco_example,
# examples/loco_starter,
# examples/loco_seaography,
examples/poem_example,
examples/proxy_gluesql_example,
examples/react_admin,
# examples/react_admin,
examples/rocket_example,
examples/rocket_okapi_example,
examples/salvo_example,
Expand Down
3 changes: 1 addition & 2 deletions sea-orm-codegen/src/entity/transformer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ impl EntityTransformer {
> 0;
col
})
.map(|col| {
.inspect(|col| {
if let sea_query::ColumnType::Enum { name, variants } = col.get_inner_col_type()
{
enums.insert(
Expand All @@ -68,7 +68,6 @@ impl EntityTransformer {
},
);
}
col
})
.collect();
let mut ref_table_counts: BTreeMap<String, usize> = BTreeMap::new();
Expand Down
8 changes: 2 additions & 6 deletions src/schema/entity.rs
Original file line number Diff line number Diff line change
Expand Up @@ -144,11 +144,7 @@ where
continue;
}
let stmt = Index::create()
.name(&format!(
"idx-{}-{}",
entity.to_string(),
column.to_string()
))
.name(format!("idx-{}-{}", entity.to_string(), column.to_string()))
.table(entity)
.col(column)
.to_owned();
Expand Down Expand Up @@ -177,7 +173,7 @@ where
for primary_key in E::PrimaryKey::iter() {
idx_pk.col(primary_key);
}
stmt.primary_key(idx_pk.name(&format!("pk-{}", entity.to_string())).primary());
stmt.primary_key(idx_pk.name(format!("pk-{}", entity.to_string())).primary());
}

for relation in E::Relation::iter() {
Expand Down

0 comments on commit 1cff03f

Please sign in to comment.