This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // database/timestamps.ts | |
| import { Kysely, sql } from 'kysely' | |
| /** | |
| * Creates a Postgres function which will update the `updated_at` column every | |
| * time the row is modified. | |
| */ | |
| export async function addPostgresTimestampFunction( | |
| db: Kysely<any>, | |
| ): Promise<void> { |