app/models/gallery.rb
# Change the permalink if it's denied
Change the permalink if it's denied
Change the permalink if it ' s denied
def change_permalink(permalink)
    base_permalink = permalink
    i = 1
    while ensure_permalink_is_not_a_route || permalink_already_use
      self.permalink = base_permalink + "-#{i}"
      i += 1
    end
  end
def change_permalink ( permalink ) base_permalink = permalink i = 1 while ensure_permalink_is_not_a_route || permalink_already_use self . permalink = base_permalink + "-#{i}" i += 1 end end
Change the permalink if it's denied
Change the permalink if it ' s denied
permalink
<not_specific>