From 9ad2409264ed0871eed6b6b41cf71355bd5c1822 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonne=20Ha=C3=9F?= Date: Sun, 28 Dec 2014 20:36:27 +0100 Subject: [PATCH] Don't use AR internals (@attributes) --- app/models/person.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/person.rb b/app/models/person.rb index 163f94e48..7dd83df26 100644 --- a/app/models/person.rb +++ b/app/models/person.rb @@ -201,12 +201,12 @@ class Person < ActiveRecord::Base def url begin - uri = URI.parse(@attributes['url']) + uri = URI.parse(self[:url]) url = "#{uri.scheme}://#{uri.host}" url += ":#{uri.port}" unless ["80", "443"].include?(uri.port.to_s) url += "/" rescue => e - url = @attributes['url'] + url = self[:url] end url end