fix bitpref references
This commit is contained in:
@@ -53,7 +53,8 @@ class DmailsController < ApplicationController
|
|||||||
Dmail.visible.unread.each do |x|
|
Dmail.visible.unread.each do |x|
|
||||||
x.update_column(:is_read, true)
|
x.update_column(:is_read, true)
|
||||||
end
|
end
|
||||||
CurrentUser.user.update_column(:has_mail, false)
|
CurrentUser.user.has_mail = false
|
||||||
|
CurrentUser.user.save
|
||||||
end
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|||||||
@@ -75,7 +75,8 @@ class User < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
|
|
||||||
def unban!
|
def unban!
|
||||||
update_column(:is_banned, false)
|
self.is_banned = false
|
||||||
|
save
|
||||||
ban.destroy
|
ban.destroy
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user