Skip to content

Commit

Permalink
Sort-reactions: Correct unsorted comments for all reactions. Fixes #42
Browse files Browse the repository at this point in the history
  • Loading branch information
Mottie committed May 8, 2018
1 parent 244e2e7 commit e89ff2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions github-sort-reactions.user.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// ==UserScript==
// @name GitHub Sort Reactions
// @version 0.2.3
// @version 0.2.4
// @description A userscript that sorts comments by reaction
// @license MIT
// @author Rob Garrison
Expand Down Expand Up @@ -94,7 +94,7 @@ thumbs down = -1)" data-sort="ACTIVE">
}

function extractSortValue(elm, type, dir) {
if (type === "NONE" || type === "ACTIVE") {
if (dir === 0 || type === "NONE" || type === "ACTIVE") {
return parseFloat(
elm.dataset[`sortComment${dir === 0 ? "Date" : "Sum"}`]
);
Expand Down

0 comments on commit e89ff2d

Please sign in to comment.