Fix issue with lazy loading temporary tiddlers

Fixes #3235
This commit is contained in:
Jermolene 2018-05-03 18:27:17 +01:00
parent 8464101430
commit ab5e5795e8
1 changed files with 10 additions and 7 deletions

View File

@ -271,13 +271,16 @@ Syncer.prototype.handleLazyLoadEvent = function(title) {
// Don't lazy load the same tiddler twice
var info = this.tiddlerInfo[title];
if(!info || !info.hasBeenLazyLoaded) {
this.createTiddlerInfo(title);
this.tiddlerInfo[title].hasBeenLazyLoaded = true;
// Queue up a sync task to load this tiddler
this.enqueueSyncTask({
type: "load",
title: title
});
// Don't lazy load if the tiddler isn't included in the sync filter
if(this.filterFn.call(this.wiki).indexOf(title) !== -1) {
this.createTiddlerInfo(title);
this.tiddlerInfo[title].hasBeenLazyLoaded = true;
// Queue up a sync task to load this tiddler
this.enqueueSyncTask({
type: "load",
title: title
});
}
}
};