mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-06-07 01:51:36 -04:00
refactor(database): run knex migrations on startup
Co-authored-by: Philip Molares <philip.molares@udo.edu> Signed-off-by: Philip Molares <philip.molares@udo.edu> Signed-off-by: Erik Michelson <github@erik.michelson.eu>
This commit is contained in:
parent
1482e5adb2
commit
3c284d1edf
85 changed files with 830 additions and 418 deletions
|
@ -3,13 +3,13 @@
|
|||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
import { FieldNameRevision } from '@hedgedoc/database';
|
||||
import { Optional } from '@mrdrogdrog/optional';
|
||||
import { BeforeApplicationShutdown, Inject, Injectable } from '@nestjs/common';
|
||||
import { OnEvent } from '@nestjs/event-emitter';
|
||||
import { SchedulerRegistry } from '@nestjs/schedule';
|
||||
|
||||
import appConfiguration, { AppConfig } from '../../config/app.config';
|
||||
import { FieldNameRevision } from '../../database/types';
|
||||
import { NoteEvent } from '../../events';
|
||||
import { ConsoleLoggerService } from '../../logger/console-logger.service';
|
||||
import { NotePermissionLevel } from '../../permissions/note-permission.enum';
|
||||
|
@ -47,6 +47,7 @@ export class RealtimeNoteService implements BeforeApplicationShutdown {
|
|||
.createRevision(
|
||||
realtimeNote.getNoteId(),
|
||||
realtimeNote.getRealtimeDoc().getCurrentContent(),
|
||||
false,
|
||||
undefined,
|
||||
realtimeNote.getRealtimeDoc().encodeStateAsUpdate(),
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue