drop unnecessary cols
This commit is contained in:
Vendored
+8
-1
@@ -124,7 +124,14 @@ export class SafelinkClient {
|
|||||||
|
|
||||||
db.db
|
db.db
|
||||||
.insertInto('safelink_rule')
|
.insertInto('safelink_rule')
|
||||||
.values(rule)
|
.values({
|
||||||
|
id: rule.id,
|
||||||
|
eventType: rule.eventType,
|
||||||
|
url: rule.url,
|
||||||
|
pattern: rule.pattern,
|
||||||
|
action: rule.action,
|
||||||
|
createdAt: rule.createdAt,
|
||||||
|
})
|
||||||
.execute()
|
.execute()
|
||||||
.catch(err => {
|
.catch(err => {
|
||||||
redirectLogger.error(
|
redirectLogger.error(
|
||||||
|
|||||||
@@ -8,10 +8,7 @@ export async function up(db: Kysely<unknown>): Promise<void> {
|
|||||||
.addColumn('url', 'varchar', col => col.notNull())
|
.addColumn('url', 'varchar', col => col.notNull())
|
||||||
.addColumn('pattern', 'varchar', col => col.notNull())
|
.addColumn('pattern', 'varchar', col => col.notNull())
|
||||||
.addColumn('action', 'varchar', col => col.notNull())
|
.addColumn('action', 'varchar', col => col.notNull())
|
||||||
.addColumn('reason', 'varchar', col => col.notNull())
|
|
||||||
.addColumn('createdBy', 'varchar', col => col.notNull())
|
|
||||||
.addColumn('createdAt', 'timestamptz', col => col.notNull())
|
.addColumn('createdAt', 'timestamptz', col => col.notNull())
|
||||||
.addColumn('comment', 'varchar', col => col.notNull())
|
|
||||||
.execute()
|
.execute()
|
||||||
|
|
||||||
await db.schema
|
await db.schema
|
||||||
|
|||||||
@@ -23,10 +23,7 @@ export interface SafelinkRule {
|
|||||||
url: string
|
url: string
|
||||||
pattern: ToolsOzoneSafelinkDefs.PatternType
|
pattern: ToolsOzoneSafelinkDefs.PatternType
|
||||||
action: ToolsOzoneSafelinkDefs.ActionType
|
action: ToolsOzoneSafelinkDefs.ActionType
|
||||||
reason: ToolsOzoneSafelinkDefs.ReasonType
|
|
||||||
createdBy: string
|
|
||||||
createdAt: string
|
createdAt: string
|
||||||
comment?: string
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SafelinkCursor {
|
export interface SafelinkCursor {
|
||||||
|
|||||||
Reference in New Issue
Block a user