@@ -32,9 +32,6 @@ extension MainContentCoordinator {
3232 ) -> [ String ] {
3333 var statements : [ String ] = [ ]
3434 let dbType = connection. type
35- let driver = DatabaseManager . shared. driver ( for: connectionId)
36- let quote : ( String ) -> String = driver? . quoteIdentifier
37- ?? quoteIdentifierFromDialect ( PluginManager . shared. sqlDialect ( for: dbType) )
3835
3936 // Sort tables for consistent execution order
4037 let sortedTruncates = truncates. sorted ( )
@@ -50,10 +47,9 @@ extension MainContentCoordinator {
5047 }
5148
5249 for tableName in sortedTruncates {
53- let quotedName = quote ( tableName)
5450 let tableOptions = options [ tableName] ?? TableOperationOptions ( )
5551 statements. append ( contentsOf: truncateStatements (
56- tableName: tableName, quotedName : quotedName , options: tableOptions, dbType : dbType
52+ tableName: tableName, options: tableOptions
5753 ) )
5854 }
5955
@@ -63,11 +59,10 @@ extension MainContentCoordinator {
6359 } ( )
6460
6561 for tableName in sortedDeletes {
66- let quotedName = quote ( tableName)
6762 let tableOptions = options [ tableName] ?? TableOperationOptions ( )
6863 let stmt = dropTableStatement (
69- tableName: tableName, quotedName : quotedName ,
70- isView: viewNames. contains ( tableName) , options: tableOptions, dbType : dbType
64+ tableName: tableName,
65+ isView: viewNames. contains ( tableName) , options: tableOptions
7166 )
7267 if !stmt. isEmpty {
7368 statements. append ( stmt)
@@ -103,7 +98,7 @@ extension MainContentCoordinator {
10398 // MARK: - Private SQL Builders
10499
105100 private func truncateStatements(
106- tableName: String , quotedName : String , options: TableOperationOptions , dbType : DatabaseType
101+ tableName: String , options: TableOperationOptions
107102 ) -> [ String ] {
108103 guard let adapter = currentPluginDriverAdapter else { return [ ] }
109104 return adapter. truncateTableStatements (
@@ -112,8 +107,7 @@ extension MainContentCoordinator {
112107 }
113108
114109 private func dropTableStatement(
115- tableName: String , quotedName: String , isView: Bool ,
116- options: TableOperationOptions , dbType: DatabaseType
110+ tableName: String , isView: Bool , options: TableOperationOptions
117111 ) -> String {
118112 let keyword = isView ? " VIEW " : " TABLE "
119113 guard let adapter = currentPluginDriverAdapter else { return " " }
0 commit comments