mirror of
https://github.com/zadam/trilium.git
synced 2025-11-09 06:45:49 +01:00
typos
This commit is contained in:
@@ -16,7 +16,7 @@ function getSharedSubTreeRoot(note) {
|
||||
}
|
||||
|
||||
// every path leads to share root, but which one to choose?
|
||||
// for sake of simplicity URLs are not note paths
|
||||
// for the sake of simplicity, URLs are not note paths
|
||||
const parentNote = note.getParentNotes()[0];
|
||||
|
||||
if (parentNote.noteId === shareRoot.SHARE_ROOT_NOTE_ID) {
|
||||
@@ -50,7 +50,7 @@ function checkAttachmentAccess(attachmentId, req, res) {
|
||||
|
||||
const note = checkNoteAccess(attachment.parentId, req, res);
|
||||
|
||||
// truthy note means user has access, and we can return the attachment
|
||||
// truthy note means the user has access, and we can return the attachment
|
||||
return note ? attachment : false;
|
||||
}
|
||||
|
||||
|
||||
@@ -330,7 +330,8 @@ class SNote extends AbstractShacaEntity {
|
||||
/**
|
||||
* @param {string} type - attribute type (label, relation, etc.)
|
||||
* @param {string} name - attribute name
|
||||
* @returns {SAttribute} attribute of given type and name. If there's more such attributes, first is returned. Returns null if there's no such attribute belonging to this note.
|
||||
* @returns {SAttribute} attribute of the given type and name. If there are more such attributes, first is returned.
|
||||
* Returns null if there's no such attribute belonging to this note.
|
||||
*/
|
||||
getAttribute(type, name) {
|
||||
const attributes = this.getAttributes();
|
||||
@@ -341,7 +342,7 @@ class SNote extends AbstractShacaEntity {
|
||||
/**
|
||||
* @param {string} type - attribute type (label, relation, etc.)
|
||||
* @param {string} name - attribute name
|
||||
* @returns {string|null} attribute value of given type and name or null if no such attribute exists.
|
||||
* @returns {string|null} attribute value of the given type and name or null if no such attribute exists.
|
||||
*/
|
||||
getAttributeValue(type, name) {
|
||||
const attr = this.getAttribute(type, name);
|
||||
@@ -352,7 +353,7 @@ class SNote extends AbstractShacaEntity {
|
||||
/**
|
||||
* @param {string} type - attribute type (label, relation, etc.)
|
||||
* @param {string} name - attribute name
|
||||
* @returns {string|null} attribute value of given type and name or null if no such attribute exists.
|
||||
* @returns {string|null} attribute value of the given type and name or null if no such attribute exists.
|
||||
*/
|
||||
getOwnedAttributeValue(type, name) {
|
||||
const attr = this.getOwnedAttribute(type, name);
|
||||
|
||||
@@ -14,7 +14,7 @@ function load() {
|
||||
const start = Date.now();
|
||||
shaca.reset();
|
||||
|
||||
// using raw query and passing arrays to avoid allocating new objects
|
||||
// using a raw query and passing arrays to avoid allocating new objects
|
||||
|
||||
const noteIds = sql.getColumn(`
|
||||
WITH RECURSIVE
|
||||
|
||||
Reference in New Issue
Block a user