( postgresId: string, postgresData: Partial<Postgres>, )
| 116 | }; |
| 117 | |
| 118 | export const updatePostgresById = async ( |
| 119 | postgresId: string, |
| 120 | postgresData: Partial<Postgres>, |
| 121 | ) => { |
| 122 | const { appName, ...rest } = postgresData; |
| 123 | const result = await db |
| 124 | .update(postgres) |
| 125 | .set({ |
| 126 | ...rest, |
| 127 | }) |
| 128 | .where(eq(postgres.postgresId, postgresId)) |
| 129 | .returning(); |
| 130 | |
| 131 | return result[0]; |
| 132 | }; |
| 133 | |
| 134 | export const removePostgresById = async (postgresId: string) => { |
| 135 | const result = await db |
no outgoing calls
no test coverage detected