Remove QuoteMarkers.cache

If posts couldn't die...
This commit is contained in:
Zixaphir 2014-03-02 19:25:34 -07:00
parent 1fc83f9b95
commit 000ca6f9ce
3 changed files with 2 additions and 15 deletions

View File

@ -5397,15 +5397,11 @@
parseQuotelink(this, quotelink, !!this.isClone);
}
},
cache: {},
parseQuotelink: function(post, quotelink, mayReset, customText) {
var board, boardID, cache, markers, postID, text, thread, threadID, _ref, _ref1, _ref2;
var board, boardID, markers, postID, text, thread, threadID, _ref, _ref1, _ref2;
_ref = post.isClone ? post.context : post, board = _ref.board, thread = _ref.thread;
markers = [];
_ref1 = Get.postDataFromLink(quotelink), boardID = _ref1.boardID, threadID = _ref1.threadID, postID = _ref1.postID;
if (cache = QuoteMarkers.cache[postID]) {
quotelink.textContent = cache;
}
if ((_ref2 = QR.db) != null ? _ref2.get({
boardID: boardID,
threadID: threadID,

View File

@ -5449,15 +5449,11 @@
parseQuotelink(this, quotelink, !!this.isClone);
}
},
cache: {},
parseQuotelink: function(post, quotelink, mayReset, customText) {
var board, boardID, cache, markers, postID, text, thread, threadID, _ref, _ref1, _ref2;
var board, boardID, markers, postID, text, thread, threadID, _ref, _ref1, _ref2;
_ref = post.isClone ? post.context : post, board = _ref.board, thread = _ref.thread;
markers = [];
_ref1 = Get.postDataFromLink(quotelink), boardID = _ref1.boardID, threadID = _ref1.threadID, postID = _ref1.postID;
if (cache = QuoteMarkers.cache[postID]) {
quotelink.textContent = cache;
}
if ((_ref2 = QR.db) != null ? _ref2.get({
boardID: boardID,
threadID: threadID,

View File

@ -11,16 +11,11 @@ QuoteMarkers =
for quotelink in @nodes.quotelinks
parseQuotelink @, quotelink, !!@isClone
return
cache: {}
parseQuotelink: (post, quotelink, mayReset, customText) ->
{board, thread} = if post.isClone then post.context else post
markers = []
{boardID, threadID, postID} = Get.postDataFromLink quotelink
if cache = QuoteMarkers.cache[postID]
quotelink.textContent = cache
if QR.db?.get {boardID, threadID, postID}
markers.push 'You'