friendly urls

This commit is contained in:
jomo
2014-09-22 06:46:08 +02:00
parent e767ec729c
commit 0f0a5c42b9
8 changed files with 37 additions and 2 deletions

View File

@@ -80,6 +80,10 @@ class User < ActiveRecord::Base
return image_tag("https://minotar.net/helm/#{CGI.escape(self.ign)}/#{CGI.escape(size.to_s)}", options)
end
def to_s
ign
end
#check if this user is an idiot and uses their mc password.
@@ -176,6 +180,10 @@ class User < ActiveRecord::Base
end
def to_param
[id, to_s.parameterize].join("-")
end