Skip to content

Commit

Permalink
just call table_name from entity.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ken-vdE authored Oct 26, 2024
1 parent f939e9e commit c0abf89
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ where
{
match db {
DatabaseConnection::SqlxPostgresPoolConnection(_) => {
let table_name = T::table_name(&entity);
let table_name = entity.table_name();
let query = format!("TRUNCATE TABLE {table_name} RESTART IDENTITY");
tracing::info!(query, "truncating postgres table {table_name}");

Expand Down

0 comments on commit c0abf89

Please sign in to comment.