Skip to content

A platform for community discussion. Free, open, simple.

DEV: revert missing license for maxmind changes (#24538)

Samc2fd090d7df4
diff --git a/app/assets/javascripts/admin/addon/components/ip-lookup.hbs b/app/assets/javascripts/admin/addon/components/ip-lookup.hbs
index 43c476e1049..1097e54a84a 100644
--- a/app/assets/javascripts/admin/addon/components/ip-lookup.hbs
+++ b/app/assets/javascripts/admin/addon/components/ip-lookup.hbs
@@ -31,15 +31,7 @@
<dt>{{i18n "ip_lookup.location"}}</dt>
<dd>
- {{#if this.location.no_license}}
- <a
- href="https://meta.discourse.org/t/configure-maxmind-for-reverse-ip-lookups/173941"
- rel="noopener noreferrer"
- target="_blank"
- >
- {{i18n "ip_lookup.no_license"}}
- </a>
- {{else if this.location.location}}
+ {{#if this.location.location}}
<a
href="https://maps.google.com/maps?q={{this.location.latitude}},{{this.location.longitude}}"
rel="noopener noreferrer"
diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml
index 4b489a9927b..053b7bcf283 100644
--- a/config/locales/client.en.yml
+++ b/config/locales/client.en.yml
@@ -1078,7 +1078,6 @@ en:
confirm_delete_other_accounts: "Are you sure you want to delete these accounts?"
powered_by: "using <a href='https://maxmind.com'>MaxMindDB</a>"
copied: "copied"
- no_license: "You must configure MaxMind to enable GeoIP information. This is configured using DISCOURSE_MAXMIND_LICENSE_KEY in your container config. If you are on a hosted Discourse service, contact your service provider."
user_fields:
none: "(select an option)"
diff --git a/lib/discourse_ip_info.rb b/lib/discourse_ip_info.rb
index 2fe0bfc7110..2949f5858cb 100644
--- a/lib/discourse_ip_info.rb
+++ b/lib/discourse_ip_info.rb
@@ -105,8 +105,6 @@ class DiscourseIpInfo
message: "IP #{ip} could not be looked up in MaxMind GeoLite2-City database.",
)
end
- else
- ret[:no_license] = true
end
if @asn_mmdb
diff --git a/spec/serializers/user_auth_token_serializer_spec.rb b/spec/serializers/user_auth_token_serializer_spec.rb
index b6ea5a887d9..f90bf21eb0b 100644
--- a/spec/serializers/user_auth_token_serializer_spec.rb
+++ b/spec/serializers/user_auth_token_serializer_spec.rb
@@ -3,7 +3,6 @@
RSpec.describe UserAuthTokenSerializer do
fab!(:user) { Fabricate(:moderator) }
let(:token) { UserAuthToken.generate!(user_id: user.id, client_ip: "2a02:ea00::", staff: true) }
- # Assign a dummy MaxMind license key, which is now checked in open_db
before(:each) { DiscourseIpInfo.open_db(File.join(Rails.root, "spec", "fixtures", "mmdb")) }