Skip to content

Commit

Permalink
Merge pull request #2656 from bomoko/feature/remove_old_problems_main
Browse files Browse the repository at this point in the history
Deletes from DB rather than marks deleted
  • Loading branch information
bomoko authored Aug 20, 2021
2 parents 257f9a0 + 4818724 commit 7e953c6
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions services/api/src/resources/problem/sql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,7 @@ export const Sql = {
environment: environment,
identifier: identifier
})
.where('deleted', '=', '0000-00-00 00:00:00')
.update({ deleted: knex.fn.now() })
.del()
.toString(),
deleteProblemsFromSource: (environment, source, service) =>
knex('environment_problem')
Expand All @@ -144,8 +143,7 @@ export const Sql = {
source: source,
lagoon_service: service
})
.where('deleted', '=', '0000-00-00 00:00:00')
.update({ deleted: knex.fn.now() })
.del()
.toString(),
selectAllProblemHarborScanMatches: () =>
knex('problem_harbor_scan_matcher')
Expand Down

0 comments on commit 7e953c6

Please sign in to comment.