mirror of
https://github.com/zadam/trilium.git
synced 2025-11-12 16:25:51 +01:00
strip # or ~ when getting attribute
This commit is contained in:
@@ -567,6 +567,10 @@ class Note extends AbstractEntity {
|
||||
* @returns {Attribute[]} note's "owned" attributes - excluding inherited ones
|
||||
*/
|
||||
getOwnedAttributes(type, name) {
|
||||
if (name && ["#", "~"].includes(name[0])) {
|
||||
name = name.substr(1);
|
||||
}
|
||||
|
||||
if (type && name) {
|
||||
return this.ownedAttributes.filter(attr => attr.type === type && attr.name === name);
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ const packageJson = require('../../package');
|
||||
const {TRILIUM_DATA_DIR} = require('./data_dir');
|
||||
|
||||
const APP_DB_VERSION = 183;
|
||||
const SYNC_VERSION = 20;
|
||||
const SYNC_VERSION = 21;
|
||||
const CLIPPER_PROTOCOL_VERSION = "1.0";
|
||||
|
||||
module.exports = {
|
||||
|
||||
Reference in New Issue
Block a user