Small oversights

This commit is contained in:
Zixaphir 2014-01-16 10:02:08 -07:00
parent 69288c7ebe
commit c32390c437
3 changed files with 2 additions and 6 deletions

View File

@ -2785,7 +2785,6 @@
sortOnTop: function(match) {
var i, offset, threadRoot, _i, _len, _ref;
offset = 0;
i = 0;
_ref = Index.sortedNodes;
for (i = _i = 0, _len = _ref.length; _i < _len; i = ++_i) {
threadRoot = _ref[i];

View File

@ -2795,7 +2795,6 @@
sortOnTop: function(match) {
var i, offset, threadRoot, _i, _len, _ref;
offset = 0;
i = 0;
_ref = Index.sortedNodes;
for (i = _i = 0, _len = _ref.length; _i < _len; i = ++_i) {
threadRoot = _ref[i];

View File

@ -415,10 +415,8 @@ Index =
sortOnTop: (match) ->
offset = 0
i = 0
for threadRoot, i in Index.sortedNodes
if match Get.threadFromRoot threadRoot
Index.sortedNodes.splice offset++, 0, Index.sortedNodes.splice(i, 1)[0]
for threadRoot, i in Index.sortedNodes when match Get.threadFromRoot threadRoot
Index.sortedNodes.splice offset++, 0, Index.sortedNodes.splice(i, 1)[0]
return
buildIndex: ->