set id outside of loop
This commit is contained in:
parent
4992151d7d
commit
15ffeb2726
@ -1694,6 +1694,7 @@
|
|||||||
},
|
},
|
||||||
node: function(root) {
|
node: function(root) {
|
||||||
var backlink, el, good, id, link, quote, _i, _j, _len, _len2, _ref, _ref2, _results;
|
var backlink, el, good, id, link, quote, _i, _j, _len, _len2, _ref, _ref2, _results;
|
||||||
|
id = $('td[id]', root).id;
|
||||||
_ref = $$('a.quotelink', root);
|
_ref = $$('a.quotelink', root);
|
||||||
_results = [];
|
_results = [];
|
||||||
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
|
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
|
||||||
@ -1702,7 +1703,6 @@
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
good = 1;
|
good = 1;
|
||||||
id = quote.parentNode.parentNode.parentNode.id;
|
|
||||||
_ref2 = $$('a.backlink', el);
|
_ref2 = $$('a.backlink', el);
|
||||||
for (_j = 0, _len2 = _ref2.length; _j < _len2; _j++) {
|
for (_j = 0, _len2 = _ref2.length; _j < _len2; _j++) {
|
||||||
backlink = _ref2[_j];
|
backlink = _ref2[_j];
|
||||||
|
|||||||
@ -1351,10 +1351,10 @@ quoteBacklink =
|
|||||||
init: ->
|
init: ->
|
||||||
g.callbacks.push quoteBacklink.node
|
g.callbacks.push quoteBacklink.node
|
||||||
node: (root) ->
|
node: (root) ->
|
||||||
|
{id} = $ 'td[id]', root
|
||||||
for quote in $$ 'a.quotelink', root
|
for quote in $$ 'a.quotelink', root
|
||||||
continue unless el = d.getElementById quote.textContent[2..]
|
continue unless el = d.getElementById quote.textContent[2..]
|
||||||
good = 1
|
good = 1
|
||||||
id = quote.parentNode.parentNode.parentNode.id
|
|
||||||
for backlink in $$ 'a.backlink', el
|
for backlink in $$ 'a.backlink', el
|
||||||
if backlink.textContent is '>>'+id
|
if backlink.textContent is '>>'+id
|
||||||
good = 0
|
good = 0
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user