mirror of
https://github.com/zadam/trilium.git
synced 2025-10-30 18:05:55 +01:00
Merge branch 'master' into next50
# Conflicts: # src/public/app/widgets/containers/root_container.js # src/services/app_info.js
This commit is contained in:
@@ -104,8 +104,9 @@ function createNewNote(params) {
|
||||
throw new Error(`Parent note "${params.parentNoteId}" not found.`);
|
||||
}
|
||||
|
||||
if (!params.title || params.title.trim().length === 0) {
|
||||
throw new Error(`Note title must not be empty`);
|
||||
if (params.title === null || params.title === undefined) {
|
||||
// empty title is allowed since it's possible to create such in the UI
|
||||
throw new Error(`Note title must be set`);
|
||||
}
|
||||
|
||||
if (params.content === null || params.content === undefined) {
|
||||
|
||||
Reference in New Issue
Block a user