diff options
Diffstat (limited to 'lib/coderay/encoders/statistic.rb')
-rw-r--r-- | lib/coderay/encoders/statistic.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/coderay/encoders/statistic.rb b/lib/coderay/encoders/statistic.rb index cd26272..b8905ff 100644 --- a/lib/coderay/encoders/statistic.rb +++ b/lib/coderay/encoders/statistic.rb @@ -64,7 +64,7 @@ Token Types (%d): @type_stats.each do |type, stat|
stat.size /= stat.count.to_f
end
- types_stats = @type_stats.sort_by { |k, v| -v.count }.map do |k, v|
+ types_stats = @type_stats.sort_by { |k, v| [-v.count, k.to_s] }.map do |k, v|
TOKEN_TYPES_ROW % [k, v.count, 100.0 * v.count / all_count, v.size]
end.join
STATS % [
|