fixes #2812: StatementInvalid exception on all Profile Pages
This commit is contained in:
@@ -130,6 +130,6 @@ class PoolVersion < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
|
|
||||||
def previous
|
def previous
|
||||||
PoolVersion.where(["pool_id = ? and updated_at < ?", pool_id, updated_at]).order("updated_at desc").first
|
PoolArchive.where(["pool_id = ? and updated_at < ?", pool_id, updated_at]).order("updated_at desc").first
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -674,7 +674,7 @@ class User < ActiveRecord::Base
|
|||||||
end
|
end
|
||||||
|
|
||||||
def pool_version_count
|
def pool_version_count
|
||||||
PoolVersion.for_user(id).count
|
PoolArchive.for_user(id).count
|
||||||
end
|
end
|
||||||
|
|
||||||
def forum_post_count
|
def forum_post_count
|
||||||
|
|||||||
Reference in New Issue
Block a user