Skip to content

Commit

Permalink
Merge pull request #645 from plicjo/master
Browse files Browse the repository at this point in the history
Fix documentation example
  • Loading branch information
norman committed Feb 13, 2015
2 parents c6ff6b9 + 3d8e715 commit b30eb85
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/friendly_id/slugged.rb
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,9 @@ def self.down
Here's an example of a class that uses a custom method to generate the slug:
class Person < ActiveRecord::Base
friendly_id :name_and_location
extend FriendlyId
friendly_id :name_and_location, use: :slugged
def name_and_location
"#{name} from #{location}"
end
Expand Down

0 comments on commit b30eb85

Please sign in to comment.