mirror of
https://github.com/zadam/trilium.git
synced 2025-06-05 01:18:44 +02:00
removed forgotten console.logs
This commit is contained in:
parent
416b7088c5
commit
5a8c3f6a2b
@ -394,7 +394,7 @@ export default class AttributeEditorWidget extends TabAwareWidget {
|
||||
}
|
||||
}
|
||||
|
||||
showHelpTooltip() {console.log("showHelpTooltip");
|
||||
showHelpTooltip() {
|
||||
this.attributeDetailWidget.hide();
|
||||
|
||||
this.$editor.tooltip({
|
||||
@ -454,7 +454,7 @@ export default class AttributeEditorWidget extends TabAwareWidget {
|
||||
attributeRenderer.renderAttribute(attribute, $attributesContainer, true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
this.textEditor.setData($attributesContainer.html());
|
||||
|
||||
if (saved) {
|
||||
|
@ -977,14 +977,12 @@ export default class NoteTreeWidget extends TabAwareWidget {
|
||||
toastService.showMessage("Auto collapsing notes after inactivity...");
|
||||
noneCollapsedYet = false;
|
||||
}
|
||||
|
||||
console.log("Auto collapsed", node.data.noteId);
|
||||
}
|
||||
}, false);
|
||||
}, 600 * 1000);
|
||||
}
|
||||
|
||||
async entitiesReloadedEvent({loadResults}) {console.log(loadResults);
|
||||
async entitiesReloadedEvent({loadResults}) {
|
||||
this.activityDetected();
|
||||
|
||||
if (loadResults.isEmptyForTree()) {
|
||||
|
@ -127,7 +127,7 @@ class ImageTypeWidget extends TypeWidget {
|
||||
|
||||
this.$widget.show();
|
||||
|
||||
const noteComplement = await this.tabContext.getNoteComplement();console.log(noteComplement, note);
|
||||
const noteComplement = await this.tabContext.getNoteComplement();
|
||||
|
||||
this.$fileName.text(attributeMap.originalFileName || "?");
|
||||
this.$fileSize.text(noteComplement.contentLength + " bytes");
|
||||
|
@ -55,8 +55,6 @@ function getRecentChanges(req) {
|
||||
|
||||
recentChanges = recentChanges.slice(0, Math.min(500, recentChanges.length));
|
||||
|
||||
console.log(recentChanges);
|
||||
|
||||
for (const change of recentChanges) {
|
||||
if (change.current_isProtected) {
|
||||
if (protectedSessionService.isProtectedSessionAvailable()) {
|
||||
|
@ -30,7 +30,7 @@ function findNotesWithExpression(expression) {
|
||||
|
||||
const noteSet = expression.execute(allNoteSet, searchContext);
|
||||
|
||||
let searchResults = noteSet.notes
|
||||
const searchResults = noteSet.notes
|
||||
.map(note => searchContext.noteIdToNotePath[note.noteId] || noteCacheService.getSomePath(note))
|
||||
.filter(notePathArray => notePathArray.includes(hoistedNoteService.getHoistedNoteId()))
|
||||
.map(notePathArray => new SearchResult(notePathArray));
|
||||
@ -70,13 +70,15 @@ function parseQueryToExpression(query, parsingContext) {
|
||||
* @return {SearchResult[]}
|
||||
*/
|
||||
function findNotesWithQuery(query, parsingContext) {
|
||||
const expression = parseQueryToExpression(query, parsingContext);
|
||||
return utils.stopWatch(`Search with query "${query}"`, () => {
|
||||
const expression = parseQueryToExpression(query, parsingContext);
|
||||
|
||||
if (!expression) {
|
||||
return [];
|
||||
}
|
||||
if (!expression) {
|
||||
return [];
|
||||
}
|
||||
|
||||
return findNotesWithExpression(expression);
|
||||
return findNotesWithExpression(expression);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -7,6 +7,7 @@ const escape = require('escape-html');
|
||||
const sanitize = require("sanitize-filename");
|
||||
const mimeTypes = require('mime-types');
|
||||
const path = require('path');
|
||||
const log = require('./log');
|
||||
|
||||
function newEntityId() {
|
||||
return randomString(12);
|
||||
@ -65,13 +66,13 @@ function prepareSqlForLike(prefix, str, suffix) {
|
||||
}
|
||||
|
||||
function stopWatch(what, func) {
|
||||
const start = new Date();
|
||||
const start = Date.now();
|
||||
|
||||
const ret = func();
|
||||
|
||||
const tookMs = Date.now() - start.getTime();
|
||||
const tookMs = Date.now() - start;
|
||||
|
||||
console.log(`${what} took ${tookMs}ms`);
|
||||
log.info(`${what} took ${tookMs}ms`);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user