Make the tw-home message refresh the page

This commit is contained in:
Jermolene
2014-07-30 22:31:15 +01:00
parent c4c4c3d270
commit 18f1634802
2 changed files with 5 additions and 6 deletions
+2 -3
View File
@@ -51,9 +51,8 @@ exports.startup = function() {
},false)
// Listen for the tw-home message
$tw.rootWidget.addEventListener("tw-home",function(event) {
var storyFilter = $tw.wiki.getTiddlerText(DEFAULT_TIDDLERS_TITLE),
storyList = $tw.wiki.filterTiddlers(storyFilter);
$tw.wiki.addTiddler({title: DEFAULT_STORY_TITLE, text: "", list: storyList},$tw.wiki.getModificationFields());
window.location.hash = "";
window.location.reload(true);
});
// Listen for the tw-permalink message
$tw.rootWidget.addEventListener("tw-permalink",function(event) {