now not creating tables with the year_ prefix and living in the gen schema by default
This commit is contained in:
@@ -24,11 +24,9 @@ fn is_valid_identifier(s: &str) -> bool {
|
||||
}
|
||||
|
||||
fn sanitize_table_name(s: &str) -> String {
|
||||
let year = OffsetDateTime::now_utc().year();
|
||||
let cleaned = s.replace(|c: char| !c.is_ascii_alphanumeric() && c != '_', "")
|
||||
s.replace(|c: char| !c.is_ascii_alphanumeric() && c != '_', "")
|
||||
.trim()
|
||||
.to_lowercase();
|
||||
format!("{}_{}", year, cleaned)
|
||||
.to_lowercase()
|
||||
}
|
||||
|
||||
fn sanitize_identifier(s: &str) -> String {
|
||||
|
||||
Reference in New Issue
Block a user