summaryrefslogtreecommitdiff
path: root/app/models/intruder.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/intruder.rb')
-rw-r--r--app/models/intruder.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/intruder.rb b/app/models/intruder.rb
index 9c01634..c305bd3 100644
--- a/app/models/intruder.rb
+++ b/app/models/intruder.rb
@@ -25,6 +25,10 @@ class Intruder < ActiveRecord::Base
key
end
+ def country
+ GeoIpCountry.find_by_ip(self.contact_ip)
+ end
+
def whois(ip_address = self.contact_ip)
if ! ip_address.blank?
begin