From cb195f4d55298f507f620fc9d456d63191eef0e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonne=20Ha=C3=9F?= Date: Sat, 31 Aug 2013 14:16:03 +0200 Subject: [PATCH] access connection through class --- app/models/profile.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/profile.rb b/app/models/profile.rb index 3e0e425e1..83c603335 100644 --- a/app/models/profile.rb +++ b/app/models/profile.rb @@ -144,7 +144,7 @@ class Profile < ActiveRecord::Base if @tag_string @tag_string else - rows = connection.select_rows( self.tags.scoped.to_sql ) + rows = self.class.connection.select_rows( self.tags.scoped.to_sql ) rows.inject(""){|string, row| string << "##{row[1]} " } end end