Skip to content

Commit

Permalink
Updated to friendly_id 4 per latest Refinery CMS edge.
Browse files Browse the repository at this point in the history
  • Loading branch information
parndt committed Feb 27, 2012
1 parent 26303c8 commit 9a2d8d3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ source 'http://rubygems.org'

gemspec

gem 'friendly_id', :git => 'git://github.com/norman/friendly_id.git'

git 'git://github.com/resolve/refinerycms.git' do
gem 'refinerycms'

Expand Down
4 changes: 2 additions & 2 deletions app/models/refinery/setting.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
module Refinery
class Setting < Refinery::Core::BaseModel
extend FriendlyId
friendly_id :name

FORM_VALUE_TYPES = [
['Multi-line', 'text_area'],
Expand All @@ -16,8 +18,6 @@ class Setting < Refinery::Core::BaseModel
attr_accessible :name, :value, :destroyable,
:scoping, :restricted, :form_value_type

has_friendly_id :name, :use_slug => true

before_save do |setting|
setting.restricted = false if setting.restricted.nil?
end
Expand Down

0 comments on commit 9a2d8d3

Please sign in to comment.