diff --git a/lib/web/note/util.ts b/lib/web/note/util.ts index 09cd60e94..3dcb42941 100644 --- a/lib/web/note/util.ts +++ b/lib/web/note/util.ts @@ -47,7 +47,7 @@ export module NoteUtils { } } - export function newNote(req: any, res: Response, body: string) { + export function newNote(req: any, res: Response, body: string | null) { let owner = null; const noteId = req.params.noteId ? req.params.noteId : null; if (req.isAuthenticated()) { diff --git a/tsconfig.json b/tsconfig.json index e69515925..ef2dd7ee8 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -2,6 +2,7 @@ "compilerOptions": { "outDir": "./built", "allowJs": true, + "strictNullChecks": true, "target": "es5", "module": "commonjs", "esModuleInterop": true