You can change the sequence seperator in configurations of friendly-id.
class Product < ActiveRecord::Base
extend FriendlyId
friendly_id :title do |config|
config.use :slugged
config.sequence_separator = ":"
end
end
The action that changes the seperator to '-' is not suggested. The document says:
The string used to separate a slug base from a numeric sequence.
By default, -- is used to separate the slug from the sequence. FriendlyId uses two dashes to distinguish sequences from slugs with numbers in their name.
You can change the default separator by setting the sequence_separator configuration option.
For obvious reasons, you should avoid setting it to “-” unless you're sure you will never want to have a friendly id with a number in it.
If you can use Rails 4, you can upgrade friendly-id to 5.0, it solves this automatically.