1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-02-19 00:15:43 +01:00

feat: add update health endpoint

This commit is contained in:
Fredrik Oseberg 2021-08-09 14:37:46 +02:00
parent 9b308be669
commit 5446038ed7

View File

@ -51,6 +51,12 @@ class ProjectStore {
return rows.map(this.mapRow);
}
async updateHealth(healthUpdate: IProjectHealthUpdate): Promise<void> {
await this.db(TABLE)
.where({ id: healthUpdate.id })
.update({ health: healthUpdate.health });
}
async get(id: string): Promise<IProject> {
return this.db
.first(COLUMNS)