(this IServiceCollection services, EnvSettings env)
| 3 | public static class GeoIPExtensions |
| 4 | { |
| 5 | public static void AddGeoIPClient(this IServiceCollection services, EnvSettings env) |
| 6 | { |
| 7 | if (env.IsManagedCloud) |
| 8 | { |
| 9 | services.AddSingleton<GeoIPClient, CloudGeoClient>(); |
| 10 | return; |
| 11 | } |
| 12 | |
| 13 | services.AddSingleton<GeoIPClient, DatabaseGeoClient>(); |
| 14 | } |
| 15 | } |