Permalink
Browse files

Revert "Make non English title indexable (such as Chinese or Japanese…

…) using MD5."

This reverts commit 70e0edf.
  • Loading branch information...
1 parent 70e0edf commit bf7b8cf6b31837ee9751cd174f128022c0fc5bb4 @tonytonyjan tonytonyjan committed Apr 29, 2012
Showing with 2 additions and 3 deletions.
  1. +2 −3 guides/rails_guides/indexer.rb
@@ -59,9 +59,8 @@ def process(string, current_level=3, counters=[1])
def title_to_idx(title)
idx = title.strip.parameterize.sub(/^\d+/, '')
- if idx.blank?
- puts "BLANK ID: please put an explicit ID for section #{title}, as in h5(#my-id)" if warnings
- idx = ("id-"+Digest::MD5.hexdigest(title.strip)).parameterize.sub(/^\d+/, '')
+ if warnings && idx.blank?
+ puts "BLANK ID: please put an explicit ID for section #{title}, as in h5(#my-id)"
end
idx
end

0 comments on commit bf7b8cf

Please sign in to comment.