From d6003649337c2565e04132a58b42f7a520eb5037 Mon Sep 17 00:00:00 2001
From: Yukai Huang
Date: Thu, 13 Oct 2016 16:25:38 +0800
Subject: Fix history deletion
---
public/js/cover.js | 1 +
public/js/history.js | 5 +++--
public/views/index.ejs | 4 +++-
3 files changed, 7 insertions(+), 3 deletions(-)
(limited to 'public')
diff --git a/public/js/cover.js b/public/js/cover.js
index 30a8e5c8..245127d1 100644
--- a/public/js/cover.js
+++ b/public/js/cover.js
@@ -17,6 +17,7 @@ var postHistoryToServer = historyModule.postHistoryToServer;
var deleteServerHistory = historyModule.deleteServerHistory;
var parseServerToHistory = historyModule.parseServerToHistory;
var saveStorageHistoryToServer = historyModule.saveStorageHistoryToServer;
+var clearDuplicatedHistory = historyModule.clearDuplicatedHistory;
var saveAs = require('file-saver').saveAs;
var List = require('list.js');
diff --git a/public/js/history.js b/public/js/history.js
index d5082dd9..8593bbcf 100644
--- a/public/js/history.js
+++ b/public/js/history.js
@@ -10,7 +10,7 @@ var extra = require('./extra');
var renderFilename = extra.renderFilename;
var md = extra.md;
-var migrateHistoryFromTempCallback = null;
+window.migrateHistoryFromTempCallback = null;
migrateHistoryFromTemp();
@@ -417,5 +417,6 @@ module.exports = {
postHistoryToServer: postHistoryToServer,
deleteServerHistory: deleteServerHistory,
parseServerToHistory: parseServerToHistory,
- saveStorageHistoryToServer: saveStorageHistoryToServer
+ saveStorageHistoryToServer: saveStorageHistoryToServer,
+ clearDuplicatedHistory: clearDuplicatedHistory
}
diff --git a/public/views/index.ejs b/public/views/index.ejs
index 0bc3dd50..e2894589 100644
--- a/public/views/index.ejs
+++ b/public/views/index.ejs
@@ -204,7 +204,9 @@
<% } %>
-
+
+
+
<%- include build/cover-scripts %>