chore: Remove over-usage of invariant (#3719)

This commit is contained in:
Tom Moor
2022-07-02 15:29:39 +03:00
committed by GitHub
parent 108b5b934a
commit c9cd424a8d
16 changed files with 34 additions and 55 deletions

View File

@@ -32,8 +32,8 @@ export default class RevisionsProcessor extends BaseProcessor {
const user = await User.findByPk(event.actorId, {
paranoid: false,
rejectOnEmpty: true,
});
invariant(user, "User should exist");
await revisionCreator({
user,
document,