mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-23 18:17:20 +00:00
Modals: don't crash if options.event is missing
Raised here: https://groups.google.com/d/msgid/tiddlywiki/3E83D2D3-42B2-4AA1-A042-52AB1D7B9B15%40gmail.com
This commit is contained in:
parent
c0dc2669c0
commit
50d0b6ee50
@ -31,7 +31,7 @@ Modal.prototype.display = function(title,options) {
|
|||||||
options = options || {};
|
options = options || {};
|
||||||
this.srcDocument = options.variables && (options.variables.rootwindow === "true" ||
|
this.srcDocument = options.variables && (options.variables.rootwindow === "true" ||
|
||||||
options.variables.rootwindow === "yes") ? document :
|
options.variables.rootwindow === "yes") ? document :
|
||||||
(options.event.event && options.event.event.target ? options.event.event.target.ownerDocument : document);
|
(options.event && options.event.event && options.event.event.target ? options.event.event.target.ownerDocument : document);
|
||||||
this.srcWindow = this.srcDocument.defaultView;
|
this.srcWindow = this.srcDocument.defaultView;
|
||||||
var self = this,
|
var self = this,
|
||||||
refreshHandler,
|
refreshHandler,
|
||||||
|
Loading…
Reference in New Issue
Block a user