repo.or.cz
/
beast-modified.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
beast rev 2066
[beast-modified.git]
/
app
/
models
/
moderatorship.rb
blob
2ca486929dc91ac2008d0e36a6ce1eae1fa6b4f1
1
class Moderatorship < ActiveRecord::Base
2
belongs_to :forum
3
belongs_to :user
4
before_create { |r| count(:id, :conditions => ['forum_id = ? and user_id = ?', r.forum_id, r.user_id]).zero? }
5
end