mirror of
https://github.com/TriliumNext/Notes.git
synced 2026-04-22 03:39:23 -05:00
22 lines
589 B
JavaScript
22 lines
589 B
JavaScript
"use strict";
|
|
|
|
class ParsingContext {
|
|
constructor(params = {}) {
|
|
this.includeNoteContent = !!params.includeNoteContent;
|
|
this.excludeArchived = !!params.excludeArchived;
|
|
this.fuzzyAttributeSearch = !!params.fuzzyAttributeSearch;
|
|
this.highlightedTokens = [];
|
|
this.originalQuery = "";
|
|
this.error = null;
|
|
}
|
|
|
|
addError(error) {
|
|
// we record only the first error, subsequent ones are usually consequence of the first
|
|
if (!this.error) {
|
|
this.error = error;
|
|
}
|
|
}
|
|
}
|
|
|
|
module.exports = ParsingContext;
|