GeoIP Detection - Version 3.0.2

Version Description

The Plugin was renamed to Geolocation IP Detection in order to prevent trademark issues.

Download this release

Release Info

Developer benjamin4
Plugin Icon 128x128 GeoIP Detection
Version 3.0.2
Comparing to
See all releases

Code changes from version 3.0.1 to 3.0.2

admin-ui.php CHANGED
@@ -25,8 +25,8 @@ function geoip_detect_menu() {
25
  require_once ABSPATH . '/wp-admin/admin.php';
26
  }
27
 
28
- add_submenu_page('tools.php', __('GeoIP Detection Lookup', 'geoip-detect'), __('GeoIP Lookup', 'geoip-detect'), 'activate_plugins', GEOIP_PLUGIN_BASENAME, 'geoip_detect_lookup_page');
29
- add_options_page(__('GeoIP Detection', 'geoip-detect'), __('GeoIP Detection', 'geoip-detect'), 'manage_options', GEOIP_PLUGIN_BASENAME, 'geoip_detect_option_page');
30
  }
31
  add_action('admin_menu', 'geoip_detect_menu');
32
 
@@ -63,7 +63,7 @@ function geoip_detect_lookup_page()
63
  case 'lookup':
64
  if (isset($_POST['ip']))
65
  {
66
- $request_ip = $_POST['ip'];
67
  $request_skipCache = !empty($_POST['skip_cache']);
68
  $options = array('skipCache' => $request_skipCache);
69
 
@@ -83,6 +83,27 @@ function geoip_detect_lookup_page()
83
  include_once(GEOIP_PLUGIN_DIR . '/views/lookup.php');
84
  }
85
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
86
  function geoip_detect_option_page() {
87
  if (!is_admin() || !current_user_can('manage_options'))
88
  return;
@@ -144,22 +165,16 @@ function geoip_detect_option_page() {
144
  // Empty IP Cache
145
  delete_transient('geoip_detect_external_ip');
146
 
147
- if (!empty($_POST['options']['external_ip'])) {
148
- if (!geoip_detect_is_ip($_POST['options']['external_ip'])) {
149
- $message .= 'The external IP "' . esc_html($_POST['options']['external_ip']) . '" is not a valid IP.';
150
- unset($_POST['options']['external_ip']);
151
- } else if (!geoip_detect_is_public_ip($_POST['options']['external_ip'])) {
152
- $message .= 'Warning: The external IP "' . esc_html($_POST['options']['external_ip']) . '" is not a public internet IP, so it will probably not work.';
153
- }
154
- }
155
-
156
-
157
  foreach ($option_names as $opt_name) {
158
  if (in_array($opt_name, $numeric_options))
159
  $opt_value = isset($_POST['options'][$opt_name]) ? (int) $_POST['options'][$opt_name] : 0;
160
- else
161
- $opt_value = isset($_POST['options'][$opt_name]) ? $_POST['options'][$opt_name] : '';
162
- update_option('geoip-detect-' . $opt_name, $opt_value);
 
 
 
 
163
  }
164
  break;
165
  }
25
  require_once ABSPATH . '/wp-admin/admin.php';
26
  }
27
 
28
+ add_submenu_page('tools.php', __('Geolocation IP Detection Lookup', 'geoip-detect'), __('Geolocation Lookup', 'geoip-detect'), 'activate_plugins', GEOIP_PLUGIN_BASENAME, 'geoip_detect_lookup_page');
29
+ add_options_page(__('Geolocation IP Detection', 'geoip-detect'), __('Geolocation IP Detection', 'geoip-detect'), 'manage_options', GEOIP_PLUGIN_BASENAME, 'geoip_detect_option_page');
30
  }
31
  add_action('admin_menu', 'geoip_detect_menu');
32
 
63
  case 'lookup':
64
  if (isset($_POST['ip']))
65
  {
66
+ $request_ip = geoip_detect_is_ip($_POST['ip']) ? $_POST['ip'] : '';
67
  $request_skipCache = !empty($_POST['skip_cache']);
68
  $options = array('skipCache' => $request_skipCache);
69
 
83
  include_once(GEOIP_PLUGIN_DIR . '/views/lookup.php');
84
  }
85
 
86
+ function geoip_detect_sanitize_option($opt_name, $opt_value, &$message = '') {
87
+ switch($opt_name) {
88
+ case 'external_ip':
89
+ if (!geoip_detect_is_ip($opt_value)) {
90
+ $message .= 'The external IP "' . esc_html($opt_value) . '" is not a valid IP.';
91
+ return false;
92
+ } else {
93
+ if (!geoip_detect_is_public_ip($opt_value)) {
94
+ $message .= 'Warning: The external IP "' . esc_html($opt_value) . '" is not a public internet IP, so it will probably not work.';
95
+ }
96
+ $opt_value = (string) $opt_value;
97
+ }
98
+
99
+ case 'trusted_proxy_ips':
100
+ $opt_value = geoip_detect_sanitize_ip_list($opt_value);
101
+ }
102
+
103
+ return $opt_value;
104
+
105
+ }
106
+
107
  function geoip_detect_option_page() {
108
  if (!is_admin() || !current_user_can('manage_options'))
109
  return;
165
  // Empty IP Cache
166
  delete_transient('geoip_detect_external_ip');
167
 
 
 
 
 
 
 
 
 
 
 
168
  foreach ($option_names as $opt_name) {
169
  if (in_array($opt_name, $numeric_options))
170
  $opt_value = isset($_POST['options'][$opt_name]) ? (int) $_POST['options'][$opt_name] : 0;
171
+ else {
172
+ $opt_value = geoip_detect_sanitize_option($opt_name, @$_POST['options'][$opt_name], $message);
173
+ }
174
+
175
+ if ($opt_value !== false) {
176
+ update_option('geoip-detect-' . $opt_name, $opt_value);
177
+ }
178
  }
179
  break;
180
  }
api.php CHANGED
@@ -83,7 +83,7 @@ function geoip_detect2_get_info_from_ip($ip, $locales = null, $options = array()
83
 
84
  /**
85
  * Filter: geoip_detect2_record_data_after_cache
86
- * After loading the information from the GeoIP-Database AND after the cache, you can add information to it.
87
  *
88
  * @param array $data Information found.
89
  * @param string $orig_ip IP that originally passed to the function.
@@ -191,7 +191,6 @@ function geoip_detect2_get_client_ip() {
191
  if (is_null($helper) || defined('GEOIP_DETECT_DOING_UNIT_TESTS')) {
192
  $helper = new GetClientIp();
193
 
194
- // TODO: Expose option to UI. comma-seperated list of IPv4 and v6 adresses.
195
  $trusted_proxies = explode(',', (string) get_option('geoip-detect-trusted_proxy_ips', ''));
196
  $helper->addProxiesToWhitelist($trusted_proxies);
197
  }
83
 
84
  /**
85
  * Filter: geoip_detect2_record_data_after_cache
86
+ * After loading the information from the Geolocation-Database AND after the cache, you can add information to it.
87
  *
88
  * @param array $data Information found.
89
  * @param string $orig_ip IP that originally passed to the function.
191
  if (is_null($helper) || defined('GEOIP_DETECT_DOING_UNIT_TESTS')) {
192
  $helper = new GetClientIp();
193
 
 
194
  $trusted_proxies = explode(',', (string) get_option('geoip-detect-trusted_proxy_ips', ''));
195
  $helper->addProxiesToWhitelist($trusted_proxies);
196
  }
check_requirements.php CHANGED
@@ -30,13 +30,13 @@ function geoip_detect_version_check() {
30
  $min = GEOIP_REQUIRED_PHP_VERSION;
31
  $yours = PHP_VERSION;
32
 
33
- $message = 'Plugin GeoIP Detection is disabled. Requires ' . $flag . ' ' .$min ." (you're using " . $flag . " " . $yours . ") ";
34
  } elseif (version_compare ( $wp_version, GEOIP_REQUIRED_WP_VERSION, '<' )) {
35
  $flag = 'WordPress';
36
  $min = GEOIP_REQUIRED_WP_VERSION;
37
  $yours = $wp_version;
38
 
39
- $message = 'Plugin GeoIP Detection is disabled. Requires ' . $flag . ' ' .$min ." (you're using " . $flag . " " . $yours . ") ";
40
  } else {
41
  return true;
42
  }
@@ -56,9 +56,9 @@ function geoip_detect_version_minimum_requirements_notice() {
56
  $wp_version = $GLOBALS['wp_version'];
57
  ?>
58
  <div class="error">
59
- <h3><?php _e( 'GeoIP Detection: Minimum requirements not met.', 'geoip-detect' ); ?></h3>
60
  <p>
61
- The plugin <strong>GeoIP Detection</strong> plugin requires PHP <?php echo GEOIP_REQUIRED_PHP_VERSION; ?> (you're using PHP <?php echo PHP_VERSION; ?>) and WordPress version <?php echo GEOIP_REQUIRED_WP_VERSION; ?> (you're using: <?php echo $wp_version; ?>) and therefore does exactly nothing.</p>
62
  <p>
63
  You can update, or install an <a href="https://github.com/yellowtree/wp-geoip-detect/releases">1.x legacy version</a> of this plugin instead.
64
  </p>
30
  $min = GEOIP_REQUIRED_PHP_VERSION;
31
  $yours = PHP_VERSION;
32
 
33
+ $message = 'Plugin Geolocation IP Detection is disabled. Requires ' . $flag . ' ' .$min ." (you're using " . $flag . " " . $yours . ") ";
34
  } elseif (version_compare ( $wp_version, GEOIP_REQUIRED_WP_VERSION, '<' )) {
35
  $flag = 'WordPress';
36
  $min = GEOIP_REQUIRED_WP_VERSION;
37
  $yours = $wp_version;
38
 
39
+ $message = 'Plugin Geolocation IP Detection is disabled. Requires ' . $flag . ' ' .$min ." (you're using " . $flag . " " . $yours . ") ";
40
  } else {
41
  return true;
42
  }
56
  $wp_version = $GLOBALS['wp_version'];
57
  ?>
58
  <div class="error">
59
+ <h3><?php _e( 'Geolocation IP Detection: Minimum requirements not met.', 'geoip-detect' ); ?></h3>
60
  <p>
61
+ The plugin <strong>Geolocation IP Detection</strong> plugin requires PHP <?php echo GEOIP_REQUIRED_PHP_VERSION; ?> (you're using PHP <?php echo PHP_VERSION; ?>) and WordPress version <?php echo GEOIP_REQUIRED_WP_VERSION; ?> (you're using: <?php echo $wp_version; ?>) and therefore does exactly nothing.</p>
62
  <p>
63
  You can update, or install an <a href="https://github.com/yellowtree/wp-geoip-detect/releases">1.x legacy version</a> of this plugin instead.
64
  </p>
composer.json CHANGED
@@ -1,6 +1,6 @@
1
  {
2
  "name": "yellowtree/geoip-detect",
3
- "description": "Wordpress Plugin GeoIP Detection: Retrieving Geo-Information using the Maxmind GeoIP2 (Lite) Database.",
4
  "type": "wordpress-plugin",
5
  "authors": [
6
  {
1
  {
2
  "name": "yellowtree/geoip-detect",
3
+ "description": "Wordpress Plugin Geolocation IP Detection: Retrieving Geo-Information using the Maxmind GeoIP2 (Lite) Database.",
4
  "type": "wordpress-plugin",
5
  "authors": [
6
  {
data-sources/abstract.php CHANGED
@@ -44,7 +44,7 @@ abstract class AbstractDataSource {
44
  *
45
  * @property bool $isEmpty (Wordpress Plugin) If the record is empty or contains any data.
46
  *
47
- * @property \YellowTree\GeoipDetect\DataSources\ExtraInformation $extra (Wordpress Plugin) Extra Information added by the GeoIP Detect plugin
48
  */
49
  class City extends \GeoIp2\Model\Insights {
50
  /**
44
  *
45
  * @property bool $isEmpty (Wordpress Plugin) If the record is empty or contains any data.
46
  *
47
+ * @property \YellowTree\GeoipDetect\DataSources\ExtraInformation $extra (Wordpress Plugin) Extra Information added by the Geolocation IP Detection plugin
48
  */
49
  class City extends \GeoIp2\Model\Insights {
50
  /**
data-sources/auto.php CHANGED
@@ -69,12 +69,16 @@ HTML;
69
 
70
  $keyAvailable = !! get_option('geoip-detect-auto_license_key', '');
71
  if (!$keyAvailable) {
72
- $error = '<div class="geoip_detect_error" style="margin-top: 10px;">' .
73
  __('Maxmind Automatic Download only works with a given license key.', 'geoip-detect') .
74
  '<p>' . sprintf(__('You can signup for a free Maxmind-Account here: <a href="%s" target="_blank">Sign Up</a>.', 'geoip-detect'), 'https://www.maxmind.com/en/geolite2/signup') . '<br>' .
75
- __('After logging in, generate a license key and copy it to the options below.', 'geoip-detect') . '</p>' .
76
- '</div>';
77
  $disabled = ' disabled="disabled"';
 
 
 
 
 
78
  }
79
 
80
  $text_update = __('Update now', 'geoip-detect');
@@ -89,6 +93,10 @@ HTML;
89
  HTML;
90
  }
91
 
 
 
 
 
92
  return $html . $error;
93
  }
94
 
@@ -97,15 +105,33 @@ HTML;
97
 
98
  if (isset($post['options_auto']['license_key'])) {
99
  $key = trim($post['options_auto']['license_key']);
100
- if (mb_strlen($key) < 16) {
101
- $message = __('The license key usually is a 16-char alphanumeric string. Are you sure this is the right key? Do not use the "unhashed format" when generating the license key.', 'geoip-detect');
102
- // Unhashed: 13char alphanumeric
103
  }
104
  update_option('geoip-detect-auto_license_key', $key);
105
  }
106
 
107
  return $message;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
108
 
 
109
  }
110
 
111
  public function __construct() {
@@ -194,6 +220,9 @@ HTML;
194
  }
195
 
196
  if (is_wp_error($tmpFile)) {
 
 
 
197
  return $tmpFile->get_error_message();
198
  }
199
  update_option('geoip-detect-auto_downloaded_file', $tmpFile);
69
 
70
  $keyAvailable = !! get_option('geoip-detect-auto_license_key', '');
71
  if (!$keyAvailable) {
72
+ $error .=
73
  __('Maxmind Automatic Download only works with a given license key.', 'geoip-detect') .
74
  '<p>' . sprintf(__('You can signup for a free Maxmind-Account here: <a href="%s" target="_blank">Sign Up</a>.', 'geoip-detect'), 'https://www.maxmind.com/en/geolite2/signup') . '<br>' .
75
+ __('After logging in, generate a license key and copy it to the options below.', 'geoip-detect') . '</p>';
 
76
  $disabled = ' disabled="disabled"';
77
+ } else {
78
+ $keyValidationMessage = $this->validateApiKey(get_option('geoip-detect-auto_license_key', ''));
79
+ if ($keyValidationMessage !== true) {
80
+ $error .= $keyValidationMessage;
81
+ }
82
  }
83
 
84
  $text_update = __('Update now', 'geoip-detect');
93
  HTML;
94
  }
95
 
96
+ if ($error) {
97
+ $error = '<div class="geoip_detect_error" style="margin-top: 10px;">' . $error . '</div>';
98
+ }
99
+
100
  return $html . $error;
101
  }
102
 
105
 
106
  if (isset($post['options_auto']['license_key'])) {
107
  $key = trim($post['options_auto']['license_key']);
108
+ $validationResult = $this->validateApiKey($key);
109
+ if (\is_string($validationResult)) {
110
+ $message .= $validationResult;
111
  }
112
  update_option('geoip-detect-auto_license_key', $key);
113
  }
114
 
115
  return $message;
116
+ }
117
+
118
+ public function validateApiKey($key) {
119
+ $message = '';
120
+ $key = trim($key);
121
+ if (mb_strlen($key) != 16) {
122
+ $message = __('The license key usually is a 16-char alphanumeric string. Are you sure this is the right key?', 'geoip-detect');
123
+ if (mb_strlen($key) < 16) {
124
+ $message .= ' ' . __('Do not use the "unhashed format" when generating the license key.', 'geoip-detect');
125
+ // Unhashed: 13char alphanumeric
126
+ }
127
+ $message .= ' ' . sprintf(__('This key is %d chars long.', 'geoip-detect'), mb_strlen($key));
128
+ } else if (1 !== preg_match('/^[a-z0-9]+$/i', $key)) {
129
+ $message = __('The license key usually is a 16-char alphanumeric string. Are you sure this is the right key?', 'geoip-detect');
130
+ $message .= ' ' . __('This key contains characters other than a-z and 0-9.', 'geoip-detect');
131
+ }
132
+ if ($message) return $message;
133
 
134
+ return true;
135
  }
136
 
137
  public function __construct() {
220
  }
221
 
222
  if (is_wp_error($tmpFile)) {
223
+ if(substr($tmpFile->get_error_message(), 0, 4) == '401:') {
224
+ return __('Error: The license key is invalid. If you have created this license key just now, please wait for some minutes and try again.', 'geoip-detect');
225
+ }
226
  return $tmpFile->get_error_message();
227
  }
228
  update_option('geoip-detect-auto_downloaded_file', $tmpFile);
data-sources/registry.php CHANGED
@@ -71,8 +71,9 @@ class DataSourceRegistry {
71
  if (isset($this->sources[$id]))
72
  return $this->sources[$id];
73
 
74
- if (WP_DEBUG)
75
  trigger_error('The source with id "' . $id . '" was requested, but no such source was found. Using default source instead.', E_USER_NOTICE);
 
76
 
77
  if (isset($this->sources[self::DEFAULT_SOURCE]))
78
  return $this->sources[self::DEFAULT_SOURCE];
71
  if (isset($this->sources[$id]))
72
  return $this->sources[$id];
73
 
74
+ if (WP_DEBUG) {
75
  trigger_error('The source with id "' . $id . '" was requested, but no such source was found. Using default source instead.', E_USER_NOTICE);
76
+ }
77
 
78
  if (isset($this->sources[self::DEFAULT_SOURCE]))
79
  return $this->sources[self::DEFAULT_SOURCE];
deprecated.php CHANGED
@@ -3,7 +3,7 @@
3
  * @deprecated If you really need to do that manually, use the AutoDataSource-Class instead.
4
  */
5
  function geoip_detect_update() {
6
- _doing_it_wrong('GeoIP Detection: geoip_detect_update', ' If you really need to do that manually, use the AutoDataSource-Class instead.', '2.4.0');
7
  $s = new \YellowTree\GeoipDetect\DataSources\Auto\AutoDataSource();
8
  return $s->maxmindUpdate();
9
  }
@@ -14,7 +14,7 @@ function geoip_detect_update() {
14
  */
15
  function geoip_detect_get_abs_db_filename()
16
  {
17
- _doing_it_wrong('GeoIP Detection: geoip_detect_get_abs_db_filename', 'geoip_detect_get_abs_db_filename should not be called directly', '2.4.0');
18
 
19
  $source = \YellowTree\GeoipDetect\DataSources\DataSourceRegistry::getInstance()->getCurrentSource();
20
  if (method_exists($source, 'maxmindGetFilename'))
3
  * @deprecated If you really need to do that manually, use the AutoDataSource-Class instead.
4
  */
5
  function geoip_detect_update() {
6
+ _doing_it_wrong('Geolocation IP Detection: geoip_detect_update', ' If you really need to do that manually, use the AutoDataSource-Class instead.', '2.4.0');
7
  $s = new \YellowTree\GeoipDetect\DataSources\Auto\AutoDataSource();
8
  return $s->maxmindUpdate();
9
  }
14
  */
15
  function geoip_detect_get_abs_db_filename()
16
  {
17
+ _doing_it_wrong('Geolocation IP Detection: geoip_detect_get_abs_db_filename', 'geoip_detect_get_abs_db_filename should not be called directly', '2.4.0');
18
 
19
  $source = \YellowTree\GeoipDetect\DataSources\DataSourceRegistry::getInstance()->getCurrentSource();
20
  if (method_exists($source, 'maxmindGetFilename'))
geoip-detect-lib.php CHANGED
@@ -37,7 +37,7 @@ function _geoip_detect2_process_options($options) {
37
 
38
  // For backwards compat 2.4.0-2.5.0
39
  if (is_bool($options)) {
40
- _doing_it_wrong('GeoIP Detection Plugin: geoip_detect2_get_info_from_ip()', '$skipCache has been renamed to $options. Instead of TRUE, now use "[\'skipCache\' => TRUE]".', '2.5.0');
41
  $value = $options;
42
  $options = array();
43
  $options['skipCache'] = $value;
@@ -209,7 +209,7 @@ function _geoip_detect2_record_enrich_data($record, $ip, $sourceId, $error) {
209
 
210
  /**
211
  * Filter: geoip_detect2_record_data
212
- * After loading the information from the GeoIP-Database, you can add information to it.
213
  *
214
  * @param array $data Information found.
215
  * @param string $orig_ip IP that originally passed to the function.
@@ -288,6 +288,18 @@ function geoip_detect_normalize_ip($ip) {
288
  return $ip;
289
  }
290
 
 
 
 
 
 
 
 
 
 
 
 
 
291
  /**
292
  * Check if the expected IP left matches the actual IP
293
  * @param string $actual IP
37
 
38
  // For backwards compat 2.4.0-2.5.0
39
  if (is_bool($options)) {
40
+ _doing_it_wrong('Geolocation IP Detection Plugin: geoip_detect2_get_info_from_ip()', '$skipCache has been renamed to $options. Instead of TRUE, now use "[\'skipCache\' => TRUE]".', '2.5.0');
41
  $value = $options;
42
  $options = array();
43
  $options['skipCache'] = $value;
209
 
210
  /**
211
  * Filter: geoip_detect2_record_data
212
+ * After loading the information from the Geolocation database, you can add information to it.
213
  *
214
  * @param array $data Information found.
215
  * @param string $orig_ip IP that originally passed to the function.
288
  return $ip;
289
  }
290
 
291
+ function geoip_detect_sanitize_ip_list($ip_list) {
292
+ $list = explode(',', $ip_list);
293
+ $ret = array();
294
+ foreach ($list as $ip) {
295
+ $ip = trim($ip);
296
+ if (!geoip_detect_is_ip($ip))
297
+ continue;
298
+ $ret[] = $ip;
299
+ }
300
+ return implode(', ', $ret);
301
+ }
302
+
303
  /**
304
  * Check if the expected IP left matches the actual IP
305
  * @param string $actual IP
geoip-detect.php CHANGED
@@ -1,11 +1,11 @@
1
  <?php
2
  /*
3
- Plugin Name: GeoIP Detection
4
  Plugin URI: http://www.yellowtree.de
5
  Description: Retrieving Geo-Information using the Maxmind GeoIP (Lite) Database.
6
  Author: Yellow Tree (Benjamin Pick)
7
  Author URI: http://www.yellowtree.de
8
- Version: 3.0.1
9
  License: GPLv3 or later
10
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
11
  Text Domain: geoip-detect
@@ -16,7 +16,7 @@ Requires WP: 4.0
16
  Requires PHP: 5.6
17
  */
18
 
19
- define('GEOIP_DETECT_VERSION', '3.0.1');
20
 
21
  /*
22
  Copyright 2013-2020 Yellow Tree, Siegen, Germany
1
  <?php
2
  /*
3
+ Plugin Name: Geolocation IP Detection
4
  Plugin URI: http://www.yellowtree.de
5
  Description: Retrieving Geo-Information using the Maxmind GeoIP (Lite) Database.
6
  Author: Yellow Tree (Benjamin Pick)
7
  Author URI: http://www.yellowtree.de
8
+ Version: 3.0.2
9
  License: GPLv3 or later
10
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
11
  Text Domain: geoip-detect
16
  Requires PHP: 5.6
17
  */
18
 
19
+ define('GEOIP_DETECT_VERSION', '3.0.2');
20
 
21
  /*
22
  Copyright 2013-2020 Yellow Tree, Siegen, Germany
init.php CHANGED
@@ -19,7 +19,7 @@ function geoip_detect_defines() {
19
  define('GEOIP_DETECT_IPV6_SUPPORTED', geoip_detect_check_ipv6_support());
20
 
21
  if (!defined('GEOIP_DETECT_USER_AGENT'))
22
- define('GEOIP_DETECT_USER_AGENT', 'GeoIP Detect ' . GEOIP_DETECT_VERSION);
23
  }
24
  add_action('plugins_loaded', 'geoip_detect_defines');
25
 
@@ -63,14 +63,14 @@ function geoip_detect_admin_notice_database_missing() {
63
  if (in_array('hostinfo_used', $ignored_notices) || !current_user_can('manage_options'))
64
  return;
65
 
66
- $url = '<a href="tools.php?page=' . GEOIP_PLUGIN_BASENAME . '">GeoIP Detection</a>';
67
  ?>
68
  <div class="error notice is-dismissible">
69
  <p style="float: right">
70
  <a href="tools.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>&geoip_detect_dismiss_notice=hostinfo_used"><?php _e('Dismiss notice', 'geoip-detect'); ?></a>
71
 
72
 
73
- <h3><?php _e( 'GeoIP Detection: No database installed', 'geoip-detect' ); ?></h3>
74
  <p><?php printf(__('The Plugin %s is currently using the Webservice <a href="http://hostip.info" target="_blank">hostip.info</a> as data source. <br />You can choose a different data source in the options page.', 'geoip-detect' ), $url); ?></p>
75
  <p><?php printf(__('For comparison of the different options, see <a href="https://github.com/yellowtree/geoip-detect/wiki/FAQ#which-data-source-should-i-choose" target="_blank">Which data source should I choose?</a>.', 'geoip-detect')); ?>
76
 
@@ -132,7 +132,7 @@ function geoip_detect_add_privacy_policy_content() {
132
  }
133
 
134
  wp_add_privacy_policy_content(
135
- 'GeoIP Detection',
136
  wp_kses_post( wpautop( $content, false ) )
137
  );
138
  }
19
  define('GEOIP_DETECT_IPV6_SUPPORTED', geoip_detect_check_ipv6_support());
20
 
21
  if (!defined('GEOIP_DETECT_USER_AGENT'))
22
+ define('GEOIP_DETECT_USER_AGENT', 'Geolocation Detect ' . GEOIP_DETECT_VERSION);
23
  }
24
  add_action('plugins_loaded', 'geoip_detect_defines');
25
 
63
  if (in_array('hostinfo_used', $ignored_notices) || !current_user_can('manage_options'))
64
  return;
65
 
66
+ $url = '<a href="tools.php?page=' . GEOIP_PLUGIN_BASENAME . '">Geolocation IP Detection</a>';
67
  ?>
68
  <div class="error notice is-dismissible">
69
  <p style="float: right">
70
  <a href="tools.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>&geoip_detect_dismiss_notice=hostinfo_used"><?php _e('Dismiss notice', 'geoip-detect'); ?></a>
71
 
72
 
73
+ <h3><?php _e( 'Geolocation IP Detection: No database installed', 'geoip-detect' ); ?></h3>
74
  <p><?php printf(__('The Plugin %s is currently using the Webservice <a href="http://hostip.info" target="_blank">hostip.info</a> as data source. <br />You can choose a different data source in the options page.', 'geoip-detect' ), $url); ?></p>
75
  <p><?php printf(__('For comparison of the different options, see <a href="https://github.com/yellowtree/geoip-detect/wiki/FAQ#which-data-source-should-i-choose" target="_blank">Which data source should I choose?</a>.', 'geoip-detect')); ?>
76
 
132
  }
133
 
134
  wp_add_privacy_policy_content(
135
+ 'Geolocation IP Detection',
136
  wp_kses_post( wpautop( $content, false ) )
137
  );
138
  }
js/dist/frontend.07674ad7.js ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ parcelRequire=function(e,r,t,n){var i,o="function"==typeof parcelRequire&&parcelRequire,u="function"==typeof require&&require;function f(t,n){if(!r[t]){if(!e[t]){var i="function"==typeof parcelRequire&&parcelRequire;if(!n&&i)return i(t,!0);if(o)return o(t,!0);if(u&&"string"==typeof t)return u(t);var c=new Error("Cannot find module '"+t+"'");throw c.code="MODULE_NOT_FOUND",c}p.resolve=function(r){return e[t][1][r]||r},p.cache={};var l=r[t]=new f.Module(t);e[t][0].call(l.exports,p,l,l.exports,this)}return r[t].exports;function p(e){return f(p.resolve(e))}}f.isParcelRequire=!0,f.Module=function(e){this.id=e,this.bundle=f,this.exports={}},f.modules=e,f.cache=r,f.parent=o,f.register=function(r,t){e[r]=[function(e,r){r.exports=t},{}]};for(var c=0;c<t.length;c++)try{f(t[c])}catch(e){i||(i=e)}if(t.length){var l=f(t[t.length-1]);"object"==typeof exports&&"undefined"!=typeof module?module.exports=l:"function"==typeof define&&define.amd?define(function(){return l}):n&&(this[n]=l)}if(parcelRequire=f,i)throw i;return f}({"LNzP":[function(require,module,exports) {
2
+ function o(t){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(o){return typeof o}:function(o){return o&&"function"==typeof Symbol&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o})(t)}function t(n){return"function"==typeof Symbol&&"symbol"===o(Symbol.iterator)?module.exports=t=function(t){return o(t)}:module.exports=t=function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":o(t)},t(n)}module.exports=t;
3
+ },{}],"KA2S":[function(require,module,exports) {
4
+ var t=function(t){"use strict";var r,e=Object.prototype,n=e.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,r,e,n){var o=r&&r.prototype instanceof v?r:v,i=Object.create(o.prototype),a=new k(n||[]);return i._invoke=function(t,r,e){var n=f;return function(o,i){if(n===l)throw new Error("Generator is already running");if(n===p){if("throw"===o)throw i;return N()}for(e.method=o,e.arg=i;;){var a=e.delegate;if(a){var c=_(a,e);if(c){if(c===y)continue;return c}}if("next"===e.method)e.sent=e._sent=e.arg;else if("throw"===e.method){if(n===f)throw n=p,e.arg;e.dispatchException(e.arg)}else"return"===e.method&&e.abrupt("return",e.arg);n=l;var u=h(t,r,e);if("normal"===u.type){if(n=e.done?p:s,u.arg===y)continue;return{value:u.arg,done:e.done}}"throw"===u.type&&(n=p,e.method="throw",e.arg=u.arg)}}}(t,e,a),i}function h(t,r,e){try{return{type:"normal",arg:t.call(r,e)}}catch(n){return{type:"throw",arg:n}}}t.wrap=u;var f="suspendedStart",s="suspendedYield",l="executing",p="completed",y={};function v(){}function d(){}function g(){}var m={};m[i]=function(){return this};var w=Object.getPrototypeOf,L=w&&w(w(G([])));L&&L!==e&&n.call(L,i)&&(m=L);var x=g.prototype=v.prototype=Object.create(m);function E(t){["next","throw","return"].forEach(function(r){t[r]=function(t){return this._invoke(r,t)}})}function b(t){var r;this._invoke=function(e,o){function i(){return new Promise(function(r,i){!function r(e,o,i,a){var c=h(t[e],t,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?Promise.resolve(f.__await).then(function(t){r("next",t,i,a)},function(t){r("throw",t,i,a)}):Promise.resolve(f).then(function(t){u.value=t,i(u)},function(t){return r("throw",t,i,a)})}a(c.arg)}(e,o,r,i)})}return r=r?r.then(i,i):i()}}function _(t,e){var n=t.iterator[e.method];if(n===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=r,_(t,e),"throw"===e.method))return y;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return y}var o=h(n,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,y;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=r),e.delegate=null,y):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,y)}function j(t){var r={tryLoc:t[0]};1 in t&&(r.catchLoc=t[1]),2 in t&&(r.finallyLoc=t[2],r.afterLoc=t[3]),this.tryEntries.push(r)}function O(t){var r=t.completion||{};r.type="normal",delete r.arg,t.completion=r}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function G(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function e(){for(;++o<t.length;)if(n.call(t,o))return e.value=t[o],e.done=!1,e;return e.value=r,e.done=!0,e};return a.next=a}}return{next:N}}function N(){return{value:r,done:!0}}return d.prototype=x.constructor=g,g.constructor=d,g[c]=d.displayName="GeneratorFunction",t.isGeneratorFunction=function(t){var r="function"==typeof t&&t.constructor;return!!r&&(r===d||"GeneratorFunction"===(r.displayName||r.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,c in t||(t[c]="GeneratorFunction")),t.prototype=Object.create(x),t},t.awrap=function(t){return{__await:t}},E(b.prototype),b.prototype[a]=function(){return this},t.AsyncIterator=b,t.async=function(r,e,n,o){var i=new b(u(r,e,n,o));return t.isGeneratorFunction(e)?i:i.next().then(function(t){return t.done?t.value:i.next()})},E(x),x[c]="Generator",x[i]=function(){return this},x.toString=function(){return"[object Generator]"},t.keys=function(t){var r=[];for(var e in t)r.push(e);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=G,k.prototype={constructor:k,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(O),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function o(n,o){return c.type="throw",c.arg=t,e.next=n,o&&(e.method="next",e.arg=r),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),h=n.call(a,"finallyLoc");if(u&&h){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!h)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,r){for(var e=this.tryEntries.length-1;e>=0;--e){var o=this.tryEntries[e];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=r&&r<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=r,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a)},complete:function(t,r){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&r&&(this.next=r),y},finish:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.finallyLoc===t)return this.complete(e.completion,e.afterLoc),O(e),y}},catch:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.tryLoc===t){var n=e.completion;if("throw"===n.type){var o=n.arg;O(e)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:G(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=r),y}},t}("object"==typeof module?module.exports:{});try{regeneratorRuntime=t}catch(r){Function("r","regeneratorRuntime = r")(t)}
5
+ },{}],"m4eR":[function(require,module,exports) {
6
+ module.exports=require("regenerator-runtime");
7
+ },{"regenerator-runtime":"KA2S"}],"ZBnv":[function(require,module,exports) {
8
+ function n(n,o){if(!(n instanceof o))throw new TypeError("Cannot call a class as a function")}module.exports=n;
9
+ },{}],"NoOd":[function(require,module,exports) {
10
+ function e(e,r){for(var n=0;n<r.length;n++){var t=r[n];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(e,t.key,t)}}function r(r,n,t){return n&&e(r.prototype,n),t&&e(r,t),r}module.exports=r;
11
+ },{}],"AuD4":[function(require,module,exports) {
12
+ var global = arguments[3];
13
+ var define;
14
+ var t,e=arguments[3],n=r(require("@babel/runtime/helpers/typeof"));function r(t){return t&&t.__esModule?t:{default:t}}(function(){var r,o="Expected a function",u="__lodash_hash_undefined__",i=500,a=1/0,c="[object AsyncFunction]",l="[object Function]",s="[object GeneratorFunction]",f="[object Null]",p="[object Proxy]",h="[object Symbol]",_="[object Undefined]",d=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,y=/^\w*$/,v=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,b=/\\(\\)?/g,g=/^\[object .+?Constructor\]$/,j="object"==(void 0===e?"undefined":(0,n.default)(e))&&e&&e.Object===Object&&e,m="object"==("undefined"==typeof self?"undefined":(0,n.default)(self))&&self&&self.Object===Object&&self,O=j||m||Function("return this")(),z="object"==("undefined"==typeof exports?"undefined":(0,n.default)(exports))&&exports&&!exports.nodeType&&exports,x=z&&"object"==("undefined"==typeof module?"undefined":(0,n.default)(module))&&module&&!module.nodeType&&module;var S,w=Array.prototype,$=Function.prototype,A=Object.prototype,F=O["__core-js_shared__"],E=$.toString,T=A.hasOwnProperty,C=(S=/[^.]+$/.exec(F&&F.keys&&F.keys.IE_PROTO||""))?"Symbol(src)_1."+S:"",P=A.toString,k=RegExp("^"+E.call(T).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),R=O.Symbol,q=w.splice,I=R?R.toStringTag:r,M=Y(O,"Map"),N=Y(Object,"create"),G=R?R.prototype:r,L=G?G.toString:r;function U(){}function V(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function B(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function D(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function H(t,e){for(var n=t.length;n--;)if(ut(t[n][0],e))return n;return-1}function J(t,e){for(var o=0,u=(e=function(t,e){if(it(t))return t;return function(t,e){if(it(t))return!1;var r=(0,n.default)(t);if("number"==r||"symbol"==r||"boolean"==r||null==t||st(t))return!0;return y.test(t)||!d.test(t)||null!=e&&t in Object(e)}(t,e)?[t]:nt(ft(t))}(e,t)).length;null!=t&&o<u;)t=t[rt(e[o++])];return o&&o==u?t:r}function K(t){return null==t?t===r?_:f:I&&I in Object(t)?function(t){var e=T.call(t,I),n=t[I];try{t[I]=r;var o=!0}catch(i){}var u=P.call(t);o&&(e?t[I]=n:delete t[I]);return u}(t):function(t){return P.call(t)}(t)}function Q(t){return!(!ct(t)||(e=t,C&&C in e))&&(at(t)?k:g).test(function(t){if(null!=t){try{return E.call(t)}catch(e){}try{return t+""}catch(e){}}return""}(t));var e}function W(t){if("string"==typeof t)return t;if(it(t))return function(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n<r;)o[n]=e(t[n],n,t);return o}(t,W)+"";if(st(t))return L?L.call(t):"";var e=t+"";return"0"==e&&1/t==-a?"-0":e}function X(t,e){var r,o,u=t.__data__;return r=e,("string"==(o=(0,n.default)(r))||"number"==o||"symbol"==o||"boolean"==o?"__proto__"!==r:null===r)?u["string"==typeof e?"string":"hash"]:u.map}function Y(t,e){var n=function(t,e){return null==t?r:t[e]}(t,e);return Q(n)?n:r}V.prototype.clear=function(){this.__data__=N?N(null):{},this.size=0},V.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},V.prototype.get=function(t){var e=this.__data__;if(N){var n=e[t];return n===u?r:n}return T.call(e,t)?e[t]:r},V.prototype.has=function(t){var e=this.__data__;return N?e[t]!==r:T.call(e,t)},V.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=N&&e===r?u:e,this},B.prototype.clear=function(){this.__data__=[],this.size=0},B.prototype.delete=function(t){var e=this.__data__,n=H(e,t);return!(n<0||(n==e.length-1?e.pop():q.call(e,n,1),--this.size,0))},B.prototype.get=function(t){var e=this.__data__,n=H(e,t);return n<0?r:e[n][1]},B.prototype.has=function(t){return H(this.__data__,t)>-1},B.prototype.set=function(t,e){var n=this.__data__,r=H(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},D.prototype.clear=function(){this.size=0,this.__data__={hash:new V,map:new(M||B),string:new V}},D.prototype.delete=function(t){var e=X(this,t).delete(t);return this.size-=e?1:0,e},D.prototype.get=function(t){return X(this,t).get(t)},D.prototype.has=function(t){return X(this,t).has(t)},D.prototype.set=function(t,e){var n=X(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};var Z,tt,et,nt=(Z=function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(v,function(t,n,r,o){e.push(r?o.replace(b,"$1"):n||t)}),e},tt=ot(Z,function(t){return et.size===i&&et.clear(),t}),et=tt.cache,tt);function rt(t){if("string"==typeof t||st(t))return t;var e=t+"";return"0"==e&&1/t==-a?"-0":e}function ot(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError(o);var n=function n(){var r=arguments,o=e?e.apply(this,r):r[0],u=n.cache;if(u.has(o))return u.get(o);var i=t.apply(this,r);return n.cache=u.set(o,i)||u,i};return n.cache=new(ot.Cache||D),n}function ut(t,e){return t===e||t!=t&&e!=e}ot.Cache=D;var it=Array.isArray;function at(t){if(!ct(t))return!1;var e=K(t);return e==l||e==s||e==c||e==p}function ct(t){var e=(0,n.default)(t);return null!=t&&("object"==e||"function"==e)}function lt(t){return null!=t&&"object"==(0,n.default)(t)}function st(t){return"symbol"==(0,n.default)(t)||lt(t)&&K(t)==h}function ft(t){return null==t?"":W(t)}U.memoize=ot,U.eq=ut,U.get=function(t,e,n){var o=null==t?r:J(t,e);return o===r?n:o},U.isArray=it,U.isFunction=at,U.isObject=ct,U.isObjectLike=lt,U.isSymbol=st,U.toString=ft,U.VERSION="4.17.5","function"==typeof t&&"object"==(0,n.default)(t.amd)&&t.amd?(O._=U,t(function(){return U})):x?((x.exports=U)._=U,z._=U):O._=U}).call(void 0);
15
+ },{"@babel/runtime/helpers/typeof":"LNzP"}],"yK6K":[function(require,module,exports) {
16
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var e=l(require("@babel/runtime/helpers/classCallCheck")),t=l(require("@babel/runtime/helpers/createClass")),r=l(require("@babel/runtime/helpers/typeof")),a=l(require("../lodash.custom"));function l(e){return e&&e.__esModule?e:{default:e}}var u=function(e,t){if("object"==(0,r.default)(e)&&"object"==(0,r.default)(e.names)){"string"==typeof t&&(t=[t]);var a=!0,l=!1,u=void 0;try{for(var n,s=t[Symbol.iterator]();!(a=(n=s.next()).done);a=!0){var i=n.value;if(e.names[i])return e.names[i]}}catch(o){l=!0,u=o}finally{try{a||null==s.return||s.return()}finally{if(l)throw u}}return""}return e},n=function(){function r(t,a){(0,e.default)(this,r),this.data={},this.default_locales=[],this.data=t||{},this.default_locales=a||["en"]}return(0,t.default)(r,[{key:"get",value:function(e,t){return this.get_with_locales(e,this.default_locales,t)}},{key:"get_with_locales",value:function(e,t,r){".name"===e.substr(-5)&&(e=e.substr(0,e.length-5));var l=a.default.get(this.data,e,r);return l=u(l,t)}},{key:"error",value:function(){return a.default.get(this.data,"extra.error","")}}]),r}(),s=n;exports.default=s;
17
+ },{"@babel/runtime/helpers/classCallCheck":"ZBnv","@babel/runtime/helpers/createClass":"NoOd","@babel/runtime/helpers/typeof":"LNzP","../lodash.custom":"AuD4"}],"lMlK":[function(require,module,exports) {
18
+ var define;
19
+ var e;!function(n){var t;if("function"==typeof e&&e.amd&&(e(n),t=!0),"object"==typeof exports&&(module.exports=n(),t=!0),!t){var o=window.Cookies,r=window.Cookies=n();r.noConflict=function(){return window.Cookies=o,r}}}(function(){function e(){for(var e=0,n={};e<arguments.length;e++){var t=arguments[e];for(var o in t)n[o]=t[o]}return n}function n(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function t(o){function r(){}function i(n,t,i){if("undefined"!=typeof document){"number"==typeof(i=e({path:"/"},r.defaults,i)).expires&&(i.expires=new Date(1*new Date+864e5*i.expires)),i.expires=i.expires?i.expires.toUTCString():"";try{var c=JSON.stringify(t);/^[\{\[]/.test(c)&&(t=c)}catch(a){}t=o.write?o.write(t,n):encodeURIComponent(String(t)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),n=encodeURIComponent(String(n)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var f="";for(var u in i)i[u]&&(f+="; "+u,!0!==i[u]&&(f+="="+i[u].split(";")[0]));return document.cookie=n+"="+t+f}}function c(e,t){if("undefined"!=typeof document){for(var r={},i=document.cookie?document.cookie.split("; "):[],c=0;c<i.length;c++){var f=i[c].split("="),u=f.slice(1).join("=");t||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{var a=n(f[0]);if(u=(o.read||o)(u,a)||n(u),t)try{u=JSON.parse(u)}catch(p){}if(r[a]=u,e===a)break}catch(p){}}return e?r[e]:r}}return r.set=i,r.get=function(e){return c(e,!1)},r.getJSON=function(e){return c(e,!0)},r.remove=function(n,t){i(n,"",e(t,{expires:-1}))},r.defaults={},r.withConverter=t,r}(function(){})});
20
+ },{}],"ZVsn":[function(require,module,exports) {
21
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.get_info=d;var e=n(require("@babel/runtime/helpers/typeof")),t=n(require("@babel/runtime/regenerator")),r=n(require("./models/record")),o=n(require("js-cookie"));function n(e){return e&&e.__esModule?e:{default:e}}window.jQuery||console.error("Geoip-detect: window.jQuery is missing!");var a=window.jQuery;window.geoip_detect||console.error("Geoip-detect: window.geoip_detect");var c=window.geoip_detect.options||{},i=null;function s(){return i||(i=a.ajax(c.ajaxurl,{dataType:"json",type:"GET",data:{action:"geoip_detect2_get_info_from_current_ip"}})),i}function u(){var e,r;return t.default.async(function(n){for(;;)switch(n.prev=n.next){case 0:return e=!1,c.cookie_name&&(e=o.default.getJSON(c.cookie_name)),n.prev=2,n.next=5,t.default.awrap(s());case 5:e=n.sent,n.next=11;break;case 8:n.prev=8,n.t0=n.catch(2),e=n.t0.responseJSON||n.t0;case 11:return c.cookie_name&&(r={path:"/"},c.cookie_duration_in_days&&(r.expires=c.cookie_duration_in_days),o.default.set(c.cookie_name,JSON.stringify(e),r)),n.abrupt("return",e);case 13:case"end":return n.stop()}},null,null,[[2,8]])}function d(){var o,n;return t.default.async(function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,t.default.awrap(u());case 2:return o=a.sent,"object"!==(0,e.default)(o)&&(console.error("Geoip-detect: Record should be an object, not a "+(0,e.default)(o),o),o={extra:{error:o||"Network error, look at the original server response ..."}}),n=new r.default(o,c.default_locales),a.abrupt("return",n);case 6:case"end":return a.stop()}})}function l(){var e,r,o,n,c,i;return t.default.async(function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,t.default.awrap(d());case 2:for((e=s.sent).error()&&console.error("Geodata Error (could not add CSS-classes to body): "+e.error()),r={country:e.get("country.iso_code"),"country-is-in-european-union":e.get("country.is_in_european_union"),continent:e.get("continent.code"),province:e.get("most_specific_subdivision.iso_code")},o=0,n=Object.keys(r);o<n.length;o++)c=n[o],(i=r[c])&&("string"==typeof i?a("body").addClass("geoip-".concat(c,"-").concat(i)):a("body").addClass("geoip-".concat(c)));case 6:case"end":return s.stop()}})}c.do_body_classes&&l(),window.geoip_detect.get_info=d;
22
+ },{"@babel/runtime/helpers/typeof":"LNzP","@babel/runtime/regenerator":"m4eR","./models/record":"yK6K","js-cookie":"lMlK"}]},{},["ZVsn"], null)
23
+ //# sourceMappingURL=/frontend.07674ad7.js.map
js/dist/frontend.07674ad7.js.map ADDED
@@ -0,0 +1 @@
 
1
+ {"version":3,"sources":["node_modules/@babel/runtime/helpers/typeof.js","node_modules/regenerator-runtime/runtime.js","node_modules/@babel/runtime/regenerator/index.js","node_modules/@babel/runtime/helpers/classCallCheck.js","node_modules/@babel/runtime/helpers/createClass.js","js/lodash.custom.js","js/models/record.js","node_modules/js-cookie/src/js.cookie.js","js/frontend.js"],"names":["undefined","FUNC_ERROR_TEXT","HASH_UNDEFINED","MAX_MEMOIZE_SIZE","INFINITY","asyncTag","funcTag","genTag","nullTag","proxyTag","symbolTag","undefinedTag","reIsDeepProp","reIsPlainProp","rePropName","reEscapeChar","reIsHostCtor","freeGlobal","global","Object","freeSelf","self","root","Function","freeExports","exports","nodeType","freeModule","module","arrayProto","uid","Array","prototype","funcProto","objectProto","coreJsData","funcToString","toString","hasOwnProperty","maskSrcKey","exec","keys","IE_PROTO","nativeObjectToString","reIsNative","RegExp","call","replace","Symbol","splice","symToStringTag","toStringTag","Map","getNative","nativeCreate","symbolProto","symbolToString","lodash","Hash","entries","index","length","clear","entry","set","ListCache","MapCache","assocIndexOf","array","key","eq","baseGet","object","path","castPath","value","isArray","isKey","type","isSymbol","test","stringToPath","toKey","baseGetTag","getRawTag","isOwn","tag","unmasked","e","result","objectToString","baseIsNative","isObject","func","isFunction","toSource","isMasked","baseToString","arrayMap","iteratee","getMapData","map","data","__data__","isKeyable","getValue","hashClear","size","hashDelete","has","get","hashGet","hashHas","hashSet","listCacheClear","listCacheDelete","pop","listCacheGet","listCacheHas","listCacheSet","push","mapCacheClear","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","cache","string","charCodeAt","match","number","quote","subString","memoize","resolver","TypeError","memoized","args","arguments","apply","Cache","other","isObjectLike","defaultValue","VERSION","define","amd","_","Record","_get_localized","ret","locales","names","locale","default_locales","prop","default_value","get_with_locales","substr","window","jQuery","console","error","$","geoip_detect","options","ajaxPromise","get_info_raw","ajax","ajaxurl","dataType","action","get_info_cached","response","cookie_name","Cookies","getJSON","responseJSON","cookie_options","cookie_duration_in_days","expires","JSON","stringify","get_info","record","add_body_classes","css_classes","country","continent","province","addClass","do_body_classes"],"mappings":";AAAA,SAAA,EAAA,GAAA,OAAA,EAAA,mBAAA,QAAA,iBAAA,OAAA,SAAA,SAAA,GAAA,cAAA,GAAA,SAAA,GAAA,OAAA,GAAA,mBAAA,QAAA,EAAA,cAAA,QAAA,IAAA,OAAA,UAAA,gBAAA,IAAA,GAEA,SAAA,EAAA,GAWA,MAVA,mBAAA,QAAA,WAAA,EAAA,OAAA,UACA,OAAA,QAAA,EAAA,SAAA,GACA,OAAA,EAAA,IAGA,OAAA,QAAA,EAAA,SAAA,GACA,OAAA,GAAA,mBAAA,QAAA,EAAA,cAAA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AA,MAAA,KAAA,EACyBF,OADzB,EAAA,KAAA,EACyBA,EAAAA,QAAAA,MAAAA,KADzB,KAAA,EAcmBpK,KAbTqK,EADV,EAAA,MAGetB,SACPD,QAAQC,MAAM,sDAAwDsB,EAAOtB,SAG3EwB,EAAc,CAChBC,QAAWH,EAAO1E,IAAI,oBACU0E,+BAAAA,EAAO1E,IAAI,gCAC3C8E,UAAWJ,EAAO1E,IAAI,kBACtB+E,SAAWL,EAAO1E,IAAI,uCAGX3F,EAAAA,EAAAA,EAAAA,OAAOsB,KAAKiJ,GAAc,EAAA,EAAA,OAAA,IAAjCrH,EAAiC,EAAA,IAC/BM,EAAQ+G,EAAYrH,MAED,iBAAVM,EACPwF,EAAE,QAAQ2B,SAAkBzH,SAAAA,OAAAA,EAAOM,KAAAA,OAAAA,IAEnCwF,EAAE,QAAQ2B,SAAkBzH,SAAAA,OAAAA,KApB5C,KAAA,EAAA,IAAA,MAAA,OAAA,EAAA,UAyBIgG,EAAQ0B,iBACRN,IAIJ1B,OAAOK,aAAamB,SAAWA","file":"frontend.07674ad7.js","sourceRoot":"../..","sourcesContent":["function _typeof2(obj) { if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof2 = function _typeof2(obj) { return typeof obj; }; } else { _typeof2 = function _typeof2(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof2(obj); }\n\nfunction _typeof(obj) {\n if (typeof Symbol === \"function\" && _typeof2(Symbol.iterator) === \"symbol\") {\n module.exports = _typeof = function _typeof(obj) {\n return _typeof2(obj);\n };\n } else {\n module.exports = _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : _typeof2(obj);\n };\n }\n\n return _typeof(obj);\n}\n\nmodule.exports = _typeof;","/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nvar runtime = (function (exports) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n exports.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n IteratorPrototype[iteratorSymbol] = function () {\n return this;\n };\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;\n GeneratorFunctionPrototype.constructor = GeneratorFunction;\n GeneratorFunctionPrototype[toStringTagSymbol] =\n GeneratorFunction.displayName = \"GeneratorFunction\";\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n prototype[method] = function(arg) {\n return this._invoke(method, arg);\n };\n });\n }\n\n exports.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n exports.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n if (!(toStringTagSymbol in genFun)) {\n genFun[toStringTagSymbol] = \"GeneratorFunction\";\n }\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n exports.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return Promise.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return Promise.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration.\n result.value = unwrapped;\n resolve(result);\n }, function(error) {\n // If a rejected Promise was yielded, throw the rejection back\n // into the async generator function so it can be handled there.\n return invoke(\"throw\", error, resolve, reject);\n });\n }\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new Promise(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n AsyncIterator.prototype[asyncIteratorSymbol] = function () {\n return this;\n };\n exports.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n exports.async = function(innerFn, outerFn, self, tryLocsList) {\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList)\n );\n\n return exports.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n // Note: [\"return\"] must be used for ES3 parsing compatibility.\n if (delegate.iterator[\"return\"]) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n Gp[toStringTagSymbol] = \"Generator\";\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n Gp[iteratorSymbol] = function() {\n return this;\n };\n\n Gp.toString = function() {\n return \"[object Generator]\";\n };\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n exports.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n exports.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n\n // Regardless of whether this script is executing as a CommonJS module\n // or not, return the runtime object so that we can declare the variable\n // regeneratorRuntime in the outer scope, which allows this module to be\n // injected easily by `bin/regenerator --include-runtime script.js`.\n return exports;\n\n}(\n // If this script is executing as a CommonJS module, use module.exports\n // as the regeneratorRuntime namespace. Otherwise create a new empty\n // object. Either way, the resulting object will be used to initialize\n // the regeneratorRuntime variable at the top of this file.\n typeof module === \"object\" ? module.exports : {}\n));\n\ntry {\n regeneratorRuntime = runtime;\n} catch (accidentalStrictMode) {\n // This module should not be running in strict mode, so the above\n // assignment should always work unless something is misconfigured. Just\n // in case runtime.js accidentally runs in strict mode, we can escape\n // strict mode using a global Function call. This could conceivably fail\n // if a Content Security Policy forbids using Function, but in that case\n // the proper solution is to fix the accidental strict mode problem. If\n // you've misconfigured your bundler to force strict mode and applied a\n // CSP to forbid Function, and you're not willing to fix either of those\n // problems, please detail your unique predicament in a GitHub issue.\n Function(\"r\", \"regeneratorRuntime = r\")(runtime);\n}\n","module.exports = require(\"regenerator-runtime\");\n","function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n\nmodule.exports = _classCallCheck;","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}\n\nmodule.exports = _createClass;","/**\n * @license\n * Lodash (Custom Build) <https://lodash.com/>\n * Build: `lodash include=\"get\" -o js/lodash.custom.js`\n * Copyright JS Foundation and other contributors <https://js.foundation/>\n * Released under MIT license <https://lodash.com/license>\n * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>\n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n;(function() {\n\n /** Used as a safe reference for `undefined` in pre-ES5 environments. */\n var undefined;\n\n /** Used as the semantic version number. */\n var VERSION = '4.17.5';\n\n /** Error message constants. */\n var FUNC_ERROR_TEXT = 'Expected a function';\n\n /** Used to stand-in for `undefined` hash values. */\n var HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n /** Used as the maximum memoize cache size. */\n var MAX_MEMOIZE_SIZE = 500;\n\n /** Used as references for various `Number` constants. */\n var INFINITY = 1 / 0;\n\n /** `Object#toString` result references. */\n var asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n nullTag = '[object Null]',\n proxyTag = '[object Proxy]',\n symbolTag = '[object Symbol]',\n undefinedTag = '[object Undefined]';\n\n /** Used to match property names within property paths. */\n var reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/,\n rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n /**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\n var reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n /** Used to match backslashes in property paths. */\n var reEscapeChar = /\\\\(\\\\)?/g;\n\n /** Used to detect host constructors (Safari). */\n var reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n /** Detect free variable `global` from Node.js. */\n var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\n /** Detect free variable `self`. */\n var freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n /** Used as a reference to the global object. */\n var root = freeGlobal || freeSelf || Function('return this')();\n\n /** Detect free variable `exports`. */\n var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n /** Detect free variable `module`. */\n var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n /*--------------------------------------------------------------------------*/\n\n /**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\n function arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n }\n\n /**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\n function getValue(object, key) {\n return object == null ? undefined : object[key];\n }\n\n /*--------------------------------------------------------------------------*/\n\n /** Used for built-in method references. */\n var arrayProto = Array.prototype,\n funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n /** Used to detect overreaching core-js shims. */\n var coreJsData = root['__core-js_shared__'];\n\n /** Used to resolve the decompiled source of functions. */\n var funcToString = funcProto.toString;\n\n /** Used to check objects for own properties. */\n var hasOwnProperty = objectProto.hasOwnProperty;\n\n /** Used to detect methods masquerading as native. */\n var maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n }());\n\n /**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\n var nativeObjectToString = objectProto.toString;\n\n /** Used to detect if a method is native. */\n var reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n );\n\n /** Built-in value references. */\n var Symbol = root.Symbol,\n splice = arrayProto.splice,\n symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n /* Built-in method references that are verified to be native. */\n var Map = getNative(root, 'Map'),\n nativeCreate = getNative(Object, 'create');\n\n /** Used to lookup unminified function names. */\n var realNames = {};\n\n /** Used to convert symbols to primitives and strings. */\n var symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a `lodash` object which wraps `value` to enable implicit method\n * chain sequences. Methods that operate on and return arrays, collections,\n * and functions can be chained together. Methods that retrieve a single value\n * or may return a primitive value will automatically end the chain sequence\n * and return the unwrapped value. Otherwise, the value must be unwrapped\n * with `_#value`.\n *\n * Explicit chain sequences, which must be unwrapped with `_#value`, may be\n * enabled using `_.chain`.\n *\n * The execution of chained methods is lazy, that is, it's deferred until\n * `_#value` is implicitly or explicitly called.\n *\n * Lazy evaluation allows several methods to support shortcut fusion.\n * Shortcut fusion is an optimization to merge iteratee calls; this avoids\n * the creation of intermediate arrays and can greatly reduce the number of\n * iteratee executions. Sections of a chain sequence qualify for shortcut\n * fusion if the section is applied to an array and iteratees accept only\n * one argument. The heuristic for whether a section qualifies for shortcut\n * fusion is subject to change.\n *\n * Chaining is supported in custom builds as long as the `_#value` method is\n * directly or indirectly included in the build.\n *\n * In addition to lodash methods, wrappers have `Array` and `String` methods.\n *\n * The wrapper `Array` methods are:\n * `concat`, `join`, `pop`, `push`, `shift`, `sort`, `splice`, and `unshift`\n *\n * The wrapper `String` methods are:\n * `replace` and `split`\n *\n * The wrapper methods that support shortcut fusion are:\n * `at`, `compact`, `drop`, `dropRight`, `dropWhile`, `filter`, `find`,\n * `findLast`, `head`, `initial`, `last`, `map`, `reject`, `reverse`, `slice`,\n * `tail`, `take`, `takeRight`, `takeRightWhile`, `takeWhile`, and `toArray`\n *\n * The chainable wrapper methods are:\n * `after`, `ary`, `assign`, `assignIn`, `assignInWith`, `assignWith`, `at`,\n * `before`, `bind`, `bindAll`, `bindKey`, `castArray`, `chain`, `chunk`,\n * `commit`, `compact`, `concat`, `conforms`, `constant`, `countBy`, `create`,\n * `curry`, `debounce`, `defaults`, `defaultsDeep`, `defer`, `delay`,\n * `difference`, `differenceBy`, `differenceWith`, `drop`, `dropRight`,\n * `dropRightWhile`, `dropWhile`, `extend`, `extendWith`, `fill`, `filter`,\n * `flatMap`, `flatMapDeep`, `flatMapDepth`, `flatten`, `flattenDeep`,\n * `flattenDepth`, `flip`, `flow`, `flowRight`, `fromPairs`, `functions`,\n * `functionsIn`, `groupBy`, `initial`, `intersection`, `intersectionBy`,\n * `intersectionWith`, `invert`, `invertBy`, `invokeMap`, `iteratee`, `keyBy`,\n * `keys`, `keysIn`, `map`, `mapKeys`, `mapValues`, `matches`, `matchesProperty`,\n * `memoize`, `merge`, `mergeWith`, `method`, `methodOf`, `mixin`, `negate`,\n * `nthArg`, `omit`, `omitBy`, `once`, `orderBy`, `over`, `overArgs`,\n * `overEvery`, `overSome`, `partial`, `partialRight`, `partition`, `pick`,\n * `pickBy`, `plant`, `property`, `propertyOf`, `pull`, `pullAll`, `pullAllBy`,\n * `pullAllWith`, `pullAt`, `push`, `range`, `rangeRight`, `rearg`, `reject`,\n * `remove`, `rest`, `reverse`, `sampleSize`, `set`, `setWith`, `shuffle`,\n * `slice`, `sort`, `sortBy`, `splice`, `spread`, `tail`, `take`, `takeRight`,\n * `takeRightWhile`, `takeWhile`, `tap`, `throttle`, `thru`, `toArray`,\n * `toPairs`, `toPairsIn`, `toPath`, `toPlainObject`, `transform`, `unary`,\n * `union`, `unionBy`, `unionWith`, `uniq`, `uniqBy`, `uniqWith`, `unset`,\n * `unshift`, `unzip`, `unzipWith`, `update`, `updateWith`, `values`,\n * `valuesIn`, `without`, `wrap`, `xor`, `xorBy`, `xorWith`, `zip`,\n * `zipObject`, `zipObjectDeep`, and `zipWith`\n *\n * The wrapper methods that are **not** chainable by default are:\n * `add`, `attempt`, `camelCase`, `capitalize`, `ceil`, `clamp`, `clone`,\n * `cloneDeep`, `cloneDeepWith`, `cloneWith`, `conformsTo`, `deburr`,\n * `defaultTo`, `divide`, `each`, `eachRight`, `endsWith`, `eq`, `escape`,\n * `escapeRegExp`, `every`, `find`, `findIndex`, `findKey`, `findLast`,\n * `findLastIndex`, `findLastKey`, `first`, `floor`, `forEach`, `forEachRight`,\n * `forIn`, `forInRight`, `forOwn`, `forOwnRight`, `get`, `gt`, `gte`, `has`,\n * `hasIn`, `head`, `identity`, `includes`, `indexOf`, `inRange`, `invoke`,\n * `isArguments`, `isArray`, `isArrayBuffer`, `isArrayLike`, `isArrayLikeObject`,\n * `isBoolean`, `isBuffer`, `isDate`, `isElement`, `isEmpty`, `isEqual`,\n * `isEqualWith`, `isError`, `isFinite`, `isFunction`, `isInteger`, `isLength`,\n * `isMap`, `isMatch`, `isMatchWith`, `isNaN`, `isNative`, `isNil`, `isNull`,\n * `isNumber`, `isObject`, `isObjectLike`, `isPlainObject`, `isRegExp`,\n * `isSafeInteger`, `isSet`, `isString`, `isUndefined`, `isTypedArray`,\n * `isWeakMap`, `isWeakSet`, `join`, `kebabCase`, `last`, `lastIndexOf`,\n * `lowerCase`, `lowerFirst`, `lt`, `lte`, `max`, `maxBy`, `mean`, `meanBy`,\n * `min`, `minBy`, `multiply`, `noConflict`, `noop`, `now`, `nth`, `pad`,\n * `padEnd`, `padStart`, `parseInt`, `pop`, `random`, `reduce`, `reduceRight`,\n * `repeat`, `result`, `round`, `runInContext`, `sample`, `shift`, `size`,\n * `snakeCase`, `some`, `sortedIndex`, `sortedIndexBy`, `sortedLastIndex`,\n * `sortedLastIndexBy`, `startCase`, `startsWith`, `stubArray`, `stubFalse`,\n * `stubObject`, `stubString`, `stubTrue`, `subtract`, `sum`, `sumBy`,\n * `template`, `times`, `toFinite`, `toInteger`, `toJSON`, `toLength`,\n * `toLower`, `toNumber`, `toSafeInteger`, `toString`, `toUpper`, `trim`,\n * `trimEnd`, `trimStart`, `truncate`, `unescape`, `uniqueId`, `upperCase`,\n * `upperFirst`, `value`, and `words`\n *\n * @name _\n * @constructor\n * @category Seq\n * @param {*} value The value to wrap in a `lodash` instance.\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * function square(n) {\n * return n * n;\n * }\n *\n * var wrapped = _([1, 2, 3]);\n *\n * // Returns an unwrapped value.\n * wrapped.reduce(_.add);\n * // => 6\n *\n * // Returns a wrapped value.\n * var squares = wrapped.map(square);\n *\n * _.isArray(squares);\n * // => false\n *\n * _.isArray(squares.value());\n * // => true\n */\n function lodash() {\n // No operation performed.\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\n function Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n }\n\n /**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\n function hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n }\n\n /**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\n function hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n }\n\n /**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\n function hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n }\n\n /**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n }\n\n /**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\n function hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n }\n\n // Add methods to `Hash`.\n Hash.prototype.clear = hashClear;\n Hash.prototype['delete'] = hashDelete;\n Hash.prototype.get = hashGet;\n Hash.prototype.has = hashHas;\n Hash.prototype.set = hashSet;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\n function ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n }\n\n /**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\n function listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n }\n\n /**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\n function listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n }\n\n /**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\n function listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n }\n\n /**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n }\n\n /**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\n function listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n }\n\n // Add methods to `ListCache`.\n ListCache.prototype.clear = listCacheClear;\n ListCache.prototype['delete'] = listCacheDelete;\n ListCache.prototype.get = listCacheGet;\n ListCache.prototype.has = listCacheHas;\n ListCache.prototype.set = listCacheSet;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\n function MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n }\n\n /**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\n function mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n }\n\n /**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\n function mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n }\n\n /**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\n function mapCacheGet(key) {\n return getMapData(this, key).get(key);\n }\n\n /**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function mapCacheHas(key) {\n return getMapData(this, key).has(key);\n }\n\n /**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\n function mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n }\n\n // Add methods to `MapCache`.\n MapCache.prototype.clear = mapCacheClear;\n MapCache.prototype['delete'] = mapCacheDelete;\n MapCache.prototype.get = mapCacheGet;\n MapCache.prototype.has = mapCacheHas;\n MapCache.prototype.set = mapCacheSet;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\n function assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n }\n\n /**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\n function baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n }\n\n /**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\n function baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n }\n\n /**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\n function baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n }\n\n /**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\n function baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n }\n\n /**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\n function castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n }\n\n /**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\n function getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n }\n\n /**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\n function getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n }\n\n /**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\n function getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n }\n\n /**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\n function isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n }\n\n /**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\n function isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n }\n\n /**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\n function isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n }\n\n /**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\n function memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n }\n\n /**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\n function objectToString(value) {\n return nativeObjectToString.call(value);\n }\n\n /**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\n var stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n });\n\n /**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\n function toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n }\n\n /**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\n function toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\n function memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n }\n\n // Expose `MapCache`.\n memoize.Cache = MapCache;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\n function eq(value, other) {\n return value === other || (value !== value && other !== other);\n }\n\n /**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\n var isArray = Array.isArray;\n\n /**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\n function isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n }\n\n /**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\n function isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n }\n\n /**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\n function isObjectLike(value) {\n return value != null && typeof value == 'object';\n }\n\n /**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\n function isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n }\n\n /**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\n function toString(value) {\n return value == null ? '' : baseToString(value);\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\n function get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n }\n\n /*------------------------------------------------------------------------*/\n\n // Add methods that return wrapped values in chain sequences.\n lodash.memoize = memoize;\n\n /*------------------------------------------------------------------------*/\n\n // Add methods that return unwrapped values in chain sequences.\n lodash.eq = eq;\n lodash.get = get;\n lodash.isArray = isArray;\n lodash.isFunction = isFunction;\n lodash.isObject = isObject;\n lodash.isObjectLike = isObjectLike;\n lodash.isSymbol = isSymbol;\n lodash.toString = toString;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * The semantic version number.\n *\n * @static\n * @memberOf _\n * @type {string}\n */\n lodash.VERSION = VERSION;\n\n /*--------------------------------------------------------------------------*/\n\n // Some AMD build optimizers, like r.js, check for condition patterns like:\n if (typeof define == 'function' && typeof define.amd == 'object' && define.amd) {\n // Expose Lodash on the global object to prevent errors when Lodash is\n // loaded by a script tag in the presence of an AMD loader.\n // See http://requirejs.org/docs/errors.html#mismatch for more details.\n // Use `_.noConflict` to remove Lodash from the global object.\n root._ = lodash;\n\n // Define as an anonymous module so, through path mapping, it can be\n // referenced as the \"underscore\" module.\n define(function() {\n return lodash;\n });\n }\n // Check for `exports` after `define` in case a build optimizer adds it.\n else if (freeModule) {\n // Export for Node.js.\n (freeModule.exports = lodash)._ = lodash;\n // Export for CommonJS support.\n freeExports._ = lodash;\n }\n else {\n // Export to the global object.\n root._ = lodash;\n }\n}.call(this));\n","\nimport _ from '../lodash.custom';\n\n\nconst _get_localized = function(ret, locales) {\n if (typeof(ret) == 'object' && typeof(ret.names) == 'object') {\n if (typeof(locales) == 'string') {\n locales = [ locales ];\n }\n\n for (let locale of locales) {\n if (ret.names[locale]) {\n return ret.names[locale];\n }\n }\n \n return '';\n }\n return ret;\n}\n\n\n\nclass Record {\n data = {};\n default_locales = [];\n\n constructor(data, default_locales) {\n this.data = data || {};\n this.default_locales = default_locales || ['en']; \n }\n\n get(prop, default_value) {\n return this.get_with_locales(prop, this.default_locales, default_value);\n }\n \n \n get_with_locales(prop, locales, default_value) {\n // Treat pseudo-property 'name' as if it never existed\n if (prop.substr(-5) === '.name') {\n prop = prop.substr(0, prop.length - 5);\n }\n\n // TODO handle most_specific_subdivision (here or in PHP)?\n\n let ret = _.get(this.data, prop, default_value);\n\n // Localize property, if possible\n ret = _get_localized(ret, locales);\n\n return ret;\n }\n \n /**\n * Get error message, if any\n * @return string Error Message\n */\n error() {\n return _.get(this.data, 'extra.error', '');\n }\n}\n\nexport default Record;","/*!\n * JavaScript Cookie v2.2.1\n * https://github.com/js-cookie/js-cookie\n *\n * Copyright 2006, 2015 Klaus Hartl & Fagner Brack\n * Released under the MIT license\n */\n;(function (factory) {\n\tvar registeredInModuleLoader;\n\tif (typeof define === 'function' && define.amd) {\n\t\tdefine(factory);\n\t\tregisteredInModuleLoader = true;\n\t}\n\tif (typeof exports === 'object') {\n\t\tmodule.exports = factory();\n\t\tregisteredInModuleLoader = true;\n\t}\n\tif (!registeredInModuleLoader) {\n\t\tvar OldCookies = window.Cookies;\n\t\tvar api = window.Cookies = factory();\n\t\tapi.noConflict = function () {\n\t\t\twindow.Cookies = OldCookies;\n\t\t\treturn api;\n\t\t};\n\t}\n}(function () {\n\tfunction extend () {\n\t\tvar i = 0;\n\t\tvar result = {};\n\t\tfor (; i < arguments.length; i++) {\n\t\t\tvar attributes = arguments[ i ];\n\t\t\tfor (var key in attributes) {\n\t\t\t\tresult[key] = attributes[key];\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}\n\n\tfunction decode (s) {\n\t\treturn s.replace(/(%[0-9A-Z]{2})+/g, decodeURIComponent);\n\t}\n\n\tfunction init (converter) {\n\t\tfunction api() {}\n\n\t\tfunction set (key, value, attributes) {\n\t\t\tif (typeof document === 'undefined') {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tattributes = extend({\n\t\t\t\tpath: '/'\n\t\t\t}, api.defaults, attributes);\n\n\t\t\tif (typeof attributes.expires === 'number') {\n\t\t\t\tattributes.expires = new Date(new Date() * 1 + attributes.expires * 864e+5);\n\t\t\t}\n\n\t\t\t// We're using \"expires\" because \"max-age\" is not supported by IE\n\t\t\tattributes.expires = attributes.expires ? attributes.expires.toUTCString() : '';\n\n\t\t\ttry {\n\t\t\t\tvar result = JSON.stringify(value);\n\t\t\t\tif (/^[\\{\\[]/.test(result)) {\n\t\t\t\t\tvalue = result;\n\t\t\t\t}\n\t\t\t} catch (e) {}\n\n\t\t\tvalue = converter.write ?\n\t\t\t\tconverter.write(value, key) :\n\t\t\t\tencodeURIComponent(String(value))\n\t\t\t\t\t.replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g, decodeURIComponent);\n\n\t\t\tkey = encodeURIComponent(String(key))\n\t\t\t\t.replace(/%(23|24|26|2B|5E|60|7C)/g, decodeURIComponent)\n\t\t\t\t.replace(/[\\(\\)]/g, escape);\n\n\t\t\tvar stringifiedAttributes = '';\n\t\t\tfor (var attributeName in attributes) {\n\t\t\t\tif (!attributes[attributeName]) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tstringifiedAttributes += '; ' + attributeName;\n\t\t\t\tif (attributes[attributeName] === true) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t// Considers RFC 6265 section 5.2:\n\t\t\t\t// ...\n\t\t\t\t// 3. If the remaining unparsed-attributes contains a %x3B (\";\")\n\t\t\t\t// character:\n\t\t\t\t// Consume the characters of the unparsed-attributes up to,\n\t\t\t\t// not including, the first %x3B (\";\") character.\n\t\t\t\t// ...\n\t\t\t\tstringifiedAttributes += '=' + attributes[attributeName].split(';')[0];\n\t\t\t}\n\n\t\t\treturn (document.cookie = key + '=' + value + stringifiedAttributes);\n\t\t}\n\n\t\tfunction get (key, json) {\n\t\t\tif (typeof document === 'undefined') {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar jar = {};\n\t\t\t// To prevent the for loop in the first place assign an empty array\n\t\t\t// in case there are no cookies at all.\n\t\t\tvar cookies = document.cookie ? document.cookie.split('; ') : [];\n\t\t\tvar i = 0;\n\n\t\t\tfor (; i < cookies.length; i++) {\n\t\t\t\tvar parts = cookies[i].split('=');\n\t\t\t\tvar cookie = parts.slice(1).join('=');\n\n\t\t\t\tif (!json && cookie.charAt(0) === '\"') {\n\t\t\t\t\tcookie = cookie.slice(1, -1);\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tvar name = decode(parts[0]);\n\t\t\t\t\tcookie = (converter.read || converter)(cookie, name) ||\n\t\t\t\t\t\tdecode(cookie);\n\n\t\t\t\t\tif (json) {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tcookie = JSON.parse(cookie);\n\t\t\t\t\t\t} catch (e) {}\n\t\t\t\t\t}\n\n\t\t\t\t\tjar[name] = cookie;\n\n\t\t\t\t\tif (key === name) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t} catch (e) {}\n\t\t\t}\n\n\t\t\treturn key ? jar[key] : jar;\n\t\t}\n\n\t\tapi.set = set;\n\t\tapi.get = function (key) {\n\t\t\treturn get(key, false /* read as raw */);\n\t\t};\n\t\tapi.getJSON = function (key) {\n\t\t\treturn get(key, true /* read as json */);\n\t\t};\n\t\tapi.remove = function (key, attributes) {\n\t\t\tset(key, '', extend(attributes, {\n\t\t\t\texpires: -1\n\t\t\t}));\n\t\t};\n\n\t\tapi.defaults = {};\n\n\t\tapi.withConverter = init;\n\n\t\treturn api;\n\t}\n\n\treturn init(function () {});\n}));\n","import Record from './models/record';\nimport Cookies from 'js-cookie';\n\nif (!window.jQuery) {\n console.error('Geoip-detect: window.jQuery is missing!');\n}\nconst $ = window.jQuery;\n\n\nif (!window.geoip_detect) {\n console.error('Geoip-detect: window.geoip_detect')\n}\nconst options = window.geoip_detect.options || {};\n\nlet ajaxPromise = null;\n\nfunction get_info_raw() {\n if (!ajaxPromise) {\n // Do Ajax Request only once per page load\n ajaxPromise = $.ajax(options.ajaxurl, {\n dataType: 'json',\n type: 'GET',\n data: {\n action: 'geoip_detect2_get_info_from_current_ip'\n }\n });\n }\n\n return ajaxPromise;\n}\n\nasync function get_info_cached() {\n let response = false;\n\n // 1) Load Info from cookie cache, if possible\n if (options.cookie_name) {\n response = Cookies.getJSON(options.cookie_name)\n }\n\n // 2) Get response\n try {\n response = await get_info_raw();\n } catch(err) {\n response = err.responseJSON || err;\n }\n\n // 3) Save info to cookie cache\n if (options.cookie_name) {\n let cookie_options = { path: '/' };\n if (options.cookie_duration_in_days) {\n cookie_options.expires = options.cookie_duration_in_days;\n }\n Cookies.set(options.cookie_name, JSON.stringify(response), cookie_options);\n }\n\n return response;\n}\n\n\nexport async function get_info() {\n let response = await get_info_cached();\n\n if (typeof(response) !== 'object') {\n console.error('Geoip-detect: Record should be an object, not a ' + typeof(response), response);\n response = { 'extra': { 'error': response || 'Network error, look at the original server response ...' }};\n }\n\n const record = new Record(response, options.default_locales);\n return record;\n}\n\nasync function add_body_classes() {\n const record = await get_info();\n\n if (record.error()) {\n console.error('Geodata Error (could not add CSS-classes to body): ' + record.error());\n }\n\n const css_classes = {\n country: record.get('country.iso_code'),\n 'country-is-in-european-union': record.get('country.is_in_european_union'),\n continent: record.get('continent.code'),\n province: record.get('most_specific_subdivision.iso_code'),\n };\n\n for(let key of Object.keys(css_classes)) {\n const value = css_classes[key];\n if (value) {\n if (typeof(value) == 'string') {\n $('body').addClass(`geoip-${key}-${value}`);\n } else {\n $('body').addClass(`geoip-${key}`);\n }\n }\n }\n}\nif (options.do_body_classes) {\n add_body_classes();\n}\n\n// Extend window object \nwindow.geoip_detect.get_info = get_info;"]}
js/dist/parcel.js CHANGED
@@ -1,3 +1,3 @@
1
  parcelRequire=function(e,r,t,n){var i,o="function"==typeof parcelRequire&&parcelRequire,u="function"==typeof require&&require;function f(t,n){if(!r[t]){if(!e[t]){var i="function"==typeof parcelRequire&&parcelRequire;if(!n&&i)return i(t,!0);if(o)return o(t,!0);if(u&&"string"==typeof t)return u(t);var c=new Error("Cannot find module '"+t+"'");throw c.code="MODULE_NOT_FOUND",c}p.resolve=function(r){return e[t][1][r]||r},p.cache={};var l=r[t]=new f.Module(t);e[t][0].call(l.exports,p,l,l.exports,this)}return r[t].exports;function p(e){return f(p.resolve(e))}}f.isParcelRequire=!0,f.Module=function(e){this.id=e,this.bundle=f,this.exports={}},f.modules=e,f.cache=r,f.parent=o,f.register=function(r,t){e[r]=[function(e,r){r.exports=t},{}]};for(var c=0;c<t.length;c++)try{f(t[c])}catch(e){i||(i=e)}if(t.length){var l=f(t[t.length-1]);"object"==typeof exports&&"undefined"!=typeof module?module.exports=l:"function"==typeof define&&define.amd?define(function(){return l}):n&&(this[n]=l)}if(parcelRequire=f,i)throw i;return f}({"mzZo":[function(require,module,exports) {
2
- module.exports={frontendJS:"/frontend.5faa9eb4.js",backendJS:"/backend.f84e1103.js"};
3
- },{"./js/frontend.js":[["frontend.5faa9eb4.js","ZVsn"],"frontend.5faa9eb4.js.map","ZVsn"],"./js/backend.js":[["backend.f84e1103.js","gP7L"],"backend.f84e1103.js.map","gP7L"]}]},{},[], null)
1
  parcelRequire=function(e,r,t,n){var i,o="function"==typeof parcelRequire&&parcelRequire,u="function"==typeof require&&require;function f(t,n){if(!r[t]){if(!e[t]){var i="function"==typeof parcelRequire&&parcelRequire;if(!n&&i)return i(t,!0);if(o)return o(t,!0);if(u&&"string"==typeof t)return u(t);var c=new Error("Cannot find module '"+t+"'");throw c.code="MODULE_NOT_FOUND",c}p.resolve=function(r){return e[t][1][r]||r},p.cache={};var l=r[t]=new f.Module(t);e[t][0].call(l.exports,p,l,l.exports,this)}return r[t].exports;function p(e){return f(p.resolve(e))}}f.isParcelRequire=!0,f.Module=function(e){this.id=e,this.bundle=f,this.exports={}},f.modules=e,f.cache=r,f.parent=o,f.register=function(r,t){e[r]=[function(e,r){r.exports=t},{}]};for(var c=0;c<t.length;c++)try{f(t[c])}catch(e){i||(i=e)}if(t.length){var l=f(t[t.length-1]);"object"==typeof exports&&"undefined"!=typeof module?module.exports=l:"function"==typeof define&&define.amd?define(function(){return l}):n&&(this[n]=l)}if(parcelRequire=f,i)throw i;return f}({"mzZo":[function(require,module,exports) {
2
+ module.exports={frontendJS:"/frontend.07674ad7.js",backendJS:"/backend.f84e1103.js"};
3
+ },{"./js/frontend.js":[["frontend.07674ad7.js","ZVsn"],"frontend.07674ad7.js.map","ZVsn"],"./js/backend.js":[["backend.f84e1103.js","gP7L"],"backend.f84e1103.js.map","gP7L"]}]},{},[], null)
js/dist/parcel.json CHANGED
@@ -1,4 +1,4 @@
1
  {
2
- "frontendJS": "/frontend.5faa9eb4.js",
3
  "backendJS": "/backend.f84e1103.js"
4
  }
1
  {
2
+ "frontendJS": "/frontend.07674ad7.js",
3
  "backendJS": "/backend.f84e1103.js"
4
  }
js/dist/parcel.urls CHANGED
@@ -1,2 +1,2 @@
1
- frontendJS: /frontend.5faa9eb4.js
2
  backendJS: /backend.f84e1103.js
1
+ frontendJS: /frontend.07674ad7.js
2
  backendJS: /backend.f84e1103.js
js/models/record.js CHANGED
@@ -4,11 +4,16 @@ import _ from '../lodash.custom';
4
 
5
  const _get_localized = function(ret, locales) {
6
  if (typeof(ret) == 'object' && typeof(ret.names) == 'object') {
 
 
 
 
7
  for (let locale of locales) {
8
  if (ret.names[locale]) {
9
  return ret.names[locale];
10
  }
11
  }
 
12
  return '';
13
  }
14
  return ret;
4
 
5
  const _get_localized = function(ret, locales) {
6
  if (typeof(ret) == 'object' && typeof(ret.names) == 'object') {
7
+ if (typeof(locales) == 'string') {
8
+ locales = [ locales ];
9
+ }
10
+
11
  for (let locale of locales) {
12
  if (ret.names[locale]) {
13
  return ret.names[locale];
14
  }
15
  }
16
+
17
  return '';
18
  }
19
  return ret;
legacy-api.php CHANGED
@@ -71,7 +71,7 @@ function geoip_detect_get_info_from_ip($ip)
71
 
72
  /**
73
  * Filter: geoip_detect_record_information
74
- * After loading the information from the GeoIP-Database, you can add or remove information from it.
75
  * @param geoiprecord $record Information found.
76
  * @param string $ip IP that was looked up
77
  * @return geoiprecord
71
 
72
  /**
73
  * Filter: geoip_detect_record_information
74
+ * After loading the information from the Geolocation database, you can add or remove information from it.
75
  * @param geoiprecord $record Information found.
76
  * @param string $ip IP that was looked up
77
  * @return geoiprecord
package.json CHANGED
@@ -1,7 +1,7 @@
1
  {
2
  "name": "geoip-detect",
3
  "version": "2.11.0",
4
- "description": "Geoip Detection - Wordpress Plugin (JS)",
5
  "main": "index.js",
6
  "repository": "git@github.com:yellowtree/geoip-detect.git",
7
  "author": "Benjamin Pick <benjaminpick@github.com>",
@@ -15,7 +15,7 @@
15
  "private": false,
16
  "dependencies": {
17
  "@babel/runtime": ">=7.7.2",
18
- "babel-plugin-transform-class-properties": ">=6.24.1",
19
  "emoji-flags": "matiassingers/emoji-flags#master",
20
  "js-cookie": "^2.2.1"
21
  },
1
  {
2
  "name": "geoip-detect",
3
  "version": "2.11.0",
4
+ "description": "Geolocation IP Detection - Wordpress Plugin (JS)",
5
  "main": "index.js",
6
  "repository": "git@github.com:yellowtree/geoip-detect.git",
7
  "author": "Benjamin Pick <benjaminpick@github.com>",
15
  "private": false,
16
  "dependencies": {
17
  "@babel/runtime": ">=7.7.2",
18
+ "babel-plugin-transform-class-properties": "^6.24.1",
19
  "emoji-flags": "matiassingers/emoji-flags#master",
20
  "js-cookie": "^2.2.1"
21
  },
readme.txt CHANGED
@@ -1,8 +1,8 @@
1
- === GeoIP Detection ===
2
  Contributors: benjaminpick
3
- Tags: geoip, maxmind, geolocation, locator
4
  Requires at least: 4.0
5
- Tested up to: 5.3
6
  Requires PHP: 5.6
7
  Stable tag: trunk
8
  License: GPLv3 or later
@@ -31,7 +31,7 @@ as a shortcode, or via CSS body classes. The city & country names are translated
31
  * Commercial Web-API: [Maxmind GeoIP2 Precision](https://www.maxmind.com/en/geoip2-precision-services) (City, Country or Insights)
32
  * Hosting-Provider dependent: [Cloudflare](https://support.cloudflare.com/hc/en-us/articles/200168236-What-does-CloudFlare-IP-Geolocation-do-) or [Amazon AWS CloudFront](https://aws.amazon.com/blogs/aws/enhanced-cloudfront-customization/) (Country)
33
  * Free or Commercial Web-API: [Ipstack](https://ipstack.com)
34
- * For the property names, see the results of a specific IP in the wordpress backend (under *Tools > GeoIP Detection*).
35
  * You can include these properties into your posts and pages by using the shortcode `[geoip_detect2 property="country.name" default="(country could not be detected)" lang="en"]` (where 'country.name' can be one of the other property names as well, and 'default' and 'lang' are optional).
36
  * You can show or hide content by using a shortcode `[geoip_detect2_show_if country="FR, DE" not_city="Berlin"]TEXT[/geoip_detect2_show_if]`. See [Shortcode Documentation](https://github.com/yellowtree/geoip-detect/wiki/API:-Shortcodes#show-or-hide-content-depending-on-the-location).
37
  * When enabled on the options page, it adds CSS classes to the body tag such as `geoip-province-HE`, `geoip-country-DE` and `geoip-continent-EU`.
@@ -39,7 +39,7 @@ as a shortcode, or via CSS body classes. The city & country names are translated
39
  * If you are using [Contact Form 7](https://wordpress.org/plugins/contact-form-7/), you can use these shortcodes:
40
  * A select input with all countries, the detected country being selected by default: `[geoip_detect2_countries mycountry]`
41
  * A text input that is pre-filled with the detected city (or other property): `[geoip_detect2_text_input city property:city lang:fr id:id class:class default:Paris]`
42
- * GeoIP information for the email text: `[geoip_detect2_user_info]`
43
 
44
  See [Documentation](https://github.com/yellowtree/geoip-detect/wiki) for more info.
45
 
@@ -106,11 +106,14 @@ Does `geoip_detect2_get_info_from_current_ip()` return the same country, regardl
106
 
107
  == Screenshots ==
108
 
109
- 1. Lookup page (under Tools > GeoIP Lookup)
110
- 2. Options page (under Preferences > GeoIP Detection)
111
 
112
  == Upgrade Notice ==
113
 
 
 
 
114
  = 3.0.1 =
115
 
116
  3.0 was not compatible with the WooCommerce plugin.
@@ -146,6 +149,11 @@ New: Shortcode for showing/hiding content!
146
 
147
  == Changelog ==
148
 
 
 
 
 
 
149
  = 3.0.1 =
150
  * FIX: Button "Update now" now works also on the lookup page.
151
  * FIX: Reverted the vendor code to the one used in 2.13 because it broke installations with the WooCommerce-plugin. I will update the vendor code again once we found a long-term solution for this interdepency.
1
+ === Geolocation IP Detection ===
2
  Contributors: benjaminpick
3
+ Tags: geolocation, locator, geoip, maxmind, ipstack
4
  Requires at least: 4.0
5
+ Tested up to: 5.4
6
  Requires PHP: 5.6
7
  Stable tag: trunk
8
  License: GPLv3 or later
31
  * Commercial Web-API: [Maxmind GeoIP2 Precision](https://www.maxmind.com/en/geoip2-precision-services) (City, Country or Insights)
32
  * Hosting-Provider dependent: [Cloudflare](https://support.cloudflare.com/hc/en-us/articles/200168236-What-does-CloudFlare-IP-Geolocation-do-) or [Amazon AWS CloudFront](https://aws.amazon.com/blogs/aws/enhanced-cloudfront-customization/) (Country)
33
  * Free or Commercial Web-API: [Ipstack](https://ipstack.com)
34
+ * For the property names, see the results of a specific IP in the wordpress backend (under *Tools > Geolocation IP Detection*).
35
  * You can include these properties into your posts and pages by using the shortcode `[geoip_detect2 property="country.name" default="(country could not be detected)" lang="en"]` (where 'country.name' can be one of the other property names as well, and 'default' and 'lang' are optional).
36
  * You can show or hide content by using a shortcode `[geoip_detect2_show_if country="FR, DE" not_city="Berlin"]TEXT[/geoip_detect2_show_if]`. See [Shortcode Documentation](https://github.com/yellowtree/geoip-detect/wiki/API:-Shortcodes#show-or-hide-content-depending-on-the-location).
37
  * When enabled on the options page, it adds CSS classes to the body tag such as `geoip-province-HE`, `geoip-country-DE` and `geoip-continent-EU`.
39
  * If you are using [Contact Form 7](https://wordpress.org/plugins/contact-form-7/), you can use these shortcodes:
40
  * A select input with all countries, the detected country being selected by default: `[geoip_detect2_countries mycountry]`
41
  * A text input that is pre-filled with the detected city (or other property): `[geoip_detect2_text_input city property:city lang:fr id:id class:class default:Paris]`
42
+ * Geolocation information for the email text: `[geoip_detect2_user_info]`
43
 
44
  See [Documentation](https://github.com/yellowtree/geoip-detect/wiki) for more info.
45
 
106
 
107
  == Screenshots ==
108
 
109
+ 1. Lookup page (under Tools > Geolocation Lookup)
110
+ 2. Options page (under Preferences > Geolocation IP Detection)
111
 
112
  == Upgrade Notice ==
113
 
114
+ = 3.0.2 =
115
+ The Plugin was renamed to Geolocation IP Detection in order to prevent trademark issues.
116
+
117
  = 3.0.1 =
118
 
119
  3.0 was not compatible with the WooCommerce plugin.
149
 
150
  == Changelog ==
151
 
152
+ = 3.0.2 =
153
+ * The Plugin has been renamed to "Geolocation IP Detection" in order to prevent trademark issues
154
+ * FIX: Minor improvements in the backend UI
155
+ * FIX: Security hardening against XSS
156
+
157
  = 3.0.1 =
158
  * FIX: Button "Update now" now works also on the lookup page.
159
  * FIX: Reverted the vendor code to the one used in 2.13 because it broke installations with the WooCommerce-plugin. I will update the vendor code again once we found a long-term solution for this interdepency.
screenshot-1.png CHANGED
Binary file
screenshot-2.png CHANGED
Binary file
shortcode.php CHANGED
@@ -28,7 +28,7 @@ function geoip_detect_shortcode($attr)
28
  $defaultValue = isset($attr['default']) ? $attr['default'] : '';
29
 
30
  if (!is_object($userInfo))
31
- return $defaultValue . '<!-- GeoIP Detect: No info found for this IP. -->';
32
 
33
  $propertyName = $attr['property'];
34
 
@@ -40,7 +40,7 @@ function geoip_detect_shortcode($attr)
40
  return $defaultValue;
41
  }
42
 
43
- return $defaultValue . '<!-- GeoIP Detect: Invalid property name. -->';
44
  }
45
  add_shortcode('geoip_detect', 'geoip_detect_shortcode');
46
 
@@ -88,12 +88,12 @@ function geoip_detect2_shortcode($attr, $content = '', $shortcodeName = 'geoip_d
88
  $userInfo = geoip_detect2_get_info_from_ip($ip, $locales, $options);
89
 
90
  if ($userInfo->isEmpty)
91
- return $defaultValue . ($attr['add_error'] ? '<!-- GeoIP Detect: No information found for this IP (' . geoip_detect2_get_client_ip() . ') -->' : '');
92
 
93
  try {
94
  $return = geoip_detect2_shortcode_get_property($userInfo, $attr['property']);
95
  } catch (\RuntimeException $e) {
96
- return $defaultValue . ($attr['add_error'] ? '<!-- GeoIP Detect: Invalid property name. -->' : '');
97
  }
98
 
99
  if (is_object($return) && $return instanceof \GeoIp2\Record\AbstractPlaceRecord) {
@@ -101,7 +101,7 @@ function geoip_detect2_shortcode($attr, $content = '', $shortcodeName = 'geoip_d
101
  }
102
 
103
  if (is_object($return) || is_array($return)) {
104
- return $defaultValue . ($attr['add_error'] ? '<!-- GeoIP Detect: Invalid property name (sub-property missing). -->' : '');
105
  }
106
 
107
  if ($return)
28
  $defaultValue = isset($attr['default']) ? $attr['default'] : '';
29
 
30
  if (!is_object($userInfo))
31
+ return $defaultValue . '<!-- Geolocation IP Detection: No info found for this IP. -->';
32
 
33
  $propertyName = $attr['property'];
34
 
40
  return $defaultValue;
41
  }
42
 
43
+ return $defaultValue . '<!-- Geolocation IP Detection: Invalid property name. -->';
44
  }
45
  add_shortcode('geoip_detect', 'geoip_detect_shortcode');
46
 
88
  $userInfo = geoip_detect2_get_info_from_ip($ip, $locales, $options);
89
 
90
  if ($userInfo->isEmpty)
91
+ return $defaultValue . ($attr['add_error'] ? '<!-- Geolocation IP Detection: No information found for this IP (' . geoip_detect2_get_client_ip() . ') -->' : '');
92
 
93
  try {
94
  $return = geoip_detect2_shortcode_get_property($userInfo, $attr['property']);
95
  } catch (\RuntimeException $e) {
96
+ return $defaultValue . ($attr['add_error'] ? '<!-- Geolocation IP Detection: Invalid property name. -->' : '');
97
  }
98
 
99
  if (is_object($return) && $return instanceof \GeoIp2\Record\AbstractPlaceRecord) {
101
  }
102
 
103
  if (is_object($return) || is_array($return)) {
104
+ return $defaultValue . ($attr['add_error'] ? '<!-- Geolocation IP Detection: Invalid property name (sub-property missing). -->' : '');
105
  }
106
 
107
  if ($return)
vendor/composer/ClassLoader.php CHANGED
@@ -279,7 +279,7 @@ class ClassLoader
279
  */
280
  public function setApcuPrefix($apcuPrefix)
281
  {
282
- $this->apcuPrefix = function_exists('apcu_fetch') && ini_get('apc.enabled') ? $apcuPrefix : null;
283
  }
284
 
285
  /**
279
  */
280
  public function setApcuPrefix($apcuPrefix)
281
  {
282
+ $this->apcuPrefix = function_exists('apcu_fetch') && filter_var(ini_get('apc.enabled'), FILTER_VALIDATE_BOOLEAN) ? $apcuPrefix : null;
283
  }
284
 
285
  /**
vendor/composer/autoload_classmap.php CHANGED
@@ -6,4 +6,52 @@ $vendorDir = dirname(dirname(__FILE__));
6
  $baseDir = dirname($vendorDir);
7
 
8
  return array(
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9
  );
6
  $baseDir = dirname($vendorDir);
7
 
8
  return array(
9
+ 'Composer\\CaBundle\\CaBundle' => $vendorDir . '/composer/ca-bundle/src/CaBundle.php',
10
+ 'GeoIp2\\Database\\Reader' => $vendorDir . '/geoip2/geoip2/src/Database/Reader.php',
11
+ 'GeoIp2\\Exception\\AddressNotFoundException' => $vendorDir . '/geoip2/geoip2/src/Exception/AddressNotFoundException.php',
12
+ 'GeoIp2\\Exception\\AuthenticationException' => $vendorDir . '/geoip2/geoip2/src/Exception/AuthenticationException.php',
13
+ 'GeoIp2\\Exception\\GeoIp2Exception' => $vendorDir . '/geoip2/geoip2/src/Exception/GeoIp2Exception.php',
14
+ 'GeoIp2\\Exception\\HttpException' => $vendorDir . '/geoip2/geoip2/src/Exception/HttpException.php',
15
+ 'GeoIp2\\Exception\\InvalidRequestException' => $vendorDir . '/geoip2/geoip2/src/Exception/InvalidRequestException.php',
16
+ 'GeoIp2\\Exception\\OutOfQueriesException' => $vendorDir . '/geoip2/geoip2/src/Exception/OutOfQueriesException.php',
17
+ 'GeoIp2\\Model\\AbstractModel' => $vendorDir . '/geoip2/geoip2/src/Model/AbstractModel.php',
18
+ 'GeoIp2\\Model\\AnonymousIp' => $vendorDir . '/geoip2/geoip2/src/Model/AnonymousIp.php',
19
+ 'GeoIp2\\Model\\Asn' => $vendorDir . '/geoip2/geoip2/src/Model/Asn.php',
20
+ 'GeoIp2\\Model\\City' => $vendorDir . '/geoip2/geoip2/src/Model/City.php',
21
+ 'GeoIp2\\Model\\ConnectionType' => $vendorDir . '/geoip2/geoip2/src/Model/ConnectionType.php',
22
+ 'GeoIp2\\Model\\Country' => $vendorDir . '/geoip2/geoip2/src/Model/Country.php',
23
+ 'GeoIp2\\Model\\Domain' => $vendorDir . '/geoip2/geoip2/src/Model/Domain.php',
24
+ 'GeoIp2\\Model\\Enterprise' => $vendorDir . '/geoip2/geoip2/src/Model/Enterprise.php',
25
+ 'GeoIp2\\Model\\Insights' => $vendorDir . '/geoip2/geoip2/src/Model/Insights.php',
26
+ 'GeoIp2\\Model\\Isp' => $vendorDir . '/geoip2/geoip2/src/Model/Isp.php',
27
+ 'GeoIp2\\ProviderInterface' => $vendorDir . '/geoip2/geoip2/src/ProviderInterface.php',
28
+ 'GeoIp2\\Record\\AbstractPlaceRecord' => $vendorDir . '/geoip2/geoip2/src/Record/AbstractPlaceRecord.php',
29
+ 'GeoIp2\\Record\\AbstractRecord' => $vendorDir . '/geoip2/geoip2/src/Record/AbstractRecord.php',
30
+ 'GeoIp2\\Record\\City' => $vendorDir . '/geoip2/geoip2/src/Record/City.php',
31
+ 'GeoIp2\\Record\\Continent' => $vendorDir . '/geoip2/geoip2/src/Record/Continent.php',
32
+ 'GeoIp2\\Record\\Country' => $vendorDir . '/geoip2/geoip2/src/Record/Country.php',
33
+ 'GeoIp2\\Record\\Location' => $vendorDir . '/geoip2/geoip2/src/Record/Location.php',
34
+ 'GeoIp2\\Record\\MaxMind' => $vendorDir . '/geoip2/geoip2/src/Record/MaxMind.php',
35
+ 'GeoIp2\\Record\\Postal' => $vendorDir . '/geoip2/geoip2/src/Record/Postal.php',
36
+ 'GeoIp2\\Record\\RepresentedCountry' => $vendorDir . '/geoip2/geoip2/src/Record/RepresentedCountry.php',
37
+ 'GeoIp2\\Record\\Subdivision' => $vendorDir . '/geoip2/geoip2/src/Record/Subdivision.php',
38
+ 'GeoIp2\\Record\\Traits' => $vendorDir . '/geoip2/geoip2/src/Record/Traits.php',
39
+ 'GeoIp2\\WebService\\Client' => $vendorDir . '/geoip2/geoip2/src/WebService/Client.php',
40
+ 'MaxMind\\Db\\Reader' => $vendorDir . '/maxmind-db/reader/src/MaxMind/Db/Reader.php',
41
+ 'MaxMind\\Db\\Reader\\Decoder' => $vendorDir . '/maxmind-db/reader/src/MaxMind/Db/Reader/Decoder.php',
42
+ 'MaxMind\\Db\\Reader\\InvalidDatabaseException' => $vendorDir . '/maxmind-db/reader/src/MaxMind/Db/Reader/InvalidDatabaseException.php',
43
+ 'MaxMind\\Db\\Reader\\Metadata' => $vendorDir . '/maxmind-db/reader/src/MaxMind/Db/Reader/Metadata.php',
44
+ 'MaxMind\\Db\\Reader\\Util' => $vendorDir . '/maxmind-db/reader/src/MaxMind/Db/Reader/Util.php',
45
+ 'MaxMind\\Exception\\AuthenticationException' => $vendorDir . '/maxmind/web-service-common/src/Exception/AuthenticationException.php',
46
+ 'MaxMind\\Exception\\HttpException' => $vendorDir . '/maxmind/web-service-common/src/Exception/HttpException.php',
47
+ 'MaxMind\\Exception\\InsufficientFundsException' => $vendorDir . '/maxmind/web-service-common/src/Exception/InsufficientFundsException.php',
48
+ 'MaxMind\\Exception\\InvalidInputException' => $vendorDir . '/maxmind/web-service-common/src/Exception/InvalidInputException.php',
49
+ 'MaxMind\\Exception\\InvalidRequestException' => $vendorDir . '/maxmind/web-service-common/src/Exception/InvalidRequestException.php',
50
+ 'MaxMind\\Exception\\IpAddressNotFoundException' => $vendorDir . '/maxmind/web-service-common/src/Exception/IpAddressNotFoundException.php',
51
+ 'MaxMind\\Exception\\PermissionRequiredException' => $vendorDir . '/maxmind/web-service-common/src/Exception/PermissionRequiredException.php',
52
+ 'MaxMind\\Exception\\WebServiceException' => $vendorDir . '/maxmind/web-service-common/src/Exception/WebServiceException.php',
53
+ 'MaxMind\\WebService\\Client' => $vendorDir . '/maxmind/web-service-common/src/WebService/Client.php',
54
+ 'MaxMind\\WebService\\Http\\CurlRequest' => $vendorDir . '/maxmind/web-service-common/src/WebService/Http/CurlRequest.php',
55
+ 'MaxMind\\WebService\\Http\\Request' => $vendorDir . '/maxmind/web-service-common/src/WebService/Http/Request.php',
56
+ 'MaxMind\\WebService\\Http\\RequestFactory' => $vendorDir . '/maxmind/web-service-common/src/WebService/Http/RequestFactory.php',
57
  );
vendor/composer/autoload_static.php CHANGED
@@ -46,11 +46,63 @@ class ComposerStaticInite354937679ffa734a3f63544e59103dd
46
  ),
47
  );
48
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
49
  public static function getInitializer(ClassLoader $loader)
50
  {
51
  return \Closure::bind(function () use ($loader) {
52
  $loader->prefixLengthsPsr4 = ComposerStaticInite354937679ffa734a3f63544e59103dd::$prefixLengthsPsr4;
53
  $loader->prefixDirsPsr4 = ComposerStaticInite354937679ffa734a3f63544e59103dd::$prefixDirsPsr4;
 
54
 
55
  }, null, ClassLoader::class);
56
  }
46
  ),
47
  );
48
 
49
+ public static $classMap = array (
50
+ 'Composer\\CaBundle\\CaBundle' => __DIR__ . '/..' . '/composer/ca-bundle/src/CaBundle.php',
51
+ 'GeoIp2\\Database\\Reader' => __DIR__ . '/..' . '/geoip2/geoip2/src/Database/Reader.php',
52
+ 'GeoIp2\\Exception\\AddressNotFoundException' => __DIR__ . '/..' . '/geoip2/geoip2/src/Exception/AddressNotFoundException.php',
53
+ 'GeoIp2\\Exception\\AuthenticationException' => __DIR__ . '/..' . '/geoip2/geoip2/src/Exception/AuthenticationException.php',
54
+ 'GeoIp2\\Exception\\GeoIp2Exception' => __DIR__ . '/..' . '/geoip2/geoip2/src/Exception/GeoIp2Exception.php',
55
+ 'GeoIp2\\Exception\\HttpException' => __DIR__ . '/..' . '/geoip2/geoip2/src/Exception/HttpException.php',
56
+ 'GeoIp2\\Exception\\InvalidRequestException' => __DIR__ . '/..' . '/geoip2/geoip2/src/Exception/InvalidRequestException.php',
57
+ 'GeoIp2\\Exception\\OutOfQueriesException' => __DIR__ . '/..' . '/geoip2/geoip2/src/Exception/OutOfQueriesException.php',
58
+ 'GeoIp2\\Model\\AbstractModel' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/AbstractModel.php',
59
+ 'GeoIp2\\Model\\AnonymousIp' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/AnonymousIp.php',
60
+ 'GeoIp2\\Model\\Asn' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/Asn.php',
61
+ 'GeoIp2\\Model\\City' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/City.php',
62
+ 'GeoIp2\\Model\\ConnectionType' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/ConnectionType.php',
63
+ 'GeoIp2\\Model\\Country' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/Country.php',
64
+ 'GeoIp2\\Model\\Domain' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/Domain.php',
65
+ 'GeoIp2\\Model\\Enterprise' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/Enterprise.php',
66
+ 'GeoIp2\\Model\\Insights' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/Insights.php',
67
+ 'GeoIp2\\Model\\Isp' => __DIR__ . '/..' . '/geoip2/geoip2/src/Model/Isp.php',
68
+ 'GeoIp2\\ProviderInterface' => __DIR__ . '/..' . '/geoip2/geoip2/src/ProviderInterface.php',
69
+ 'GeoIp2\\Record\\AbstractPlaceRecord' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/AbstractPlaceRecord.php',
70
+ 'GeoIp2\\Record\\AbstractRecord' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/AbstractRecord.php',
71
+ 'GeoIp2\\Record\\City' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/City.php',
72
+ 'GeoIp2\\Record\\Continent' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/Continent.php',
73
+ 'GeoIp2\\Record\\Country' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/Country.php',
74
+ 'GeoIp2\\Record\\Location' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/Location.php',
75
+ 'GeoIp2\\Record\\MaxMind' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/MaxMind.php',
76
+ 'GeoIp2\\Record\\Postal' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/Postal.php',
77
+ 'GeoIp2\\Record\\RepresentedCountry' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/RepresentedCountry.php',
78
+ 'GeoIp2\\Record\\Subdivision' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/Subdivision.php',
79
+ 'GeoIp2\\Record\\Traits' => __DIR__ . '/..' . '/geoip2/geoip2/src/Record/Traits.php',
80
+ 'GeoIp2\\WebService\\Client' => __DIR__ . '/..' . '/geoip2/geoip2/src/WebService/Client.php',
81
+ 'MaxMind\\Db\\Reader' => __DIR__ . '/..' . '/maxmind-db/reader/src/MaxMind/Db/Reader.php',
82
+ 'MaxMind\\Db\\Reader\\Decoder' => __DIR__ . '/..' . '/maxmind-db/reader/src/MaxMind/Db/Reader/Decoder.php',
83
+ 'MaxMind\\Db\\Reader\\InvalidDatabaseException' => __DIR__ . '/..' . '/maxmind-db/reader/src/MaxMind/Db/Reader/InvalidDatabaseException.php',
84
+ 'MaxMind\\Db\\Reader\\Metadata' => __DIR__ . '/..' . '/maxmind-db/reader/src/MaxMind/Db/Reader/Metadata.php',
85
+ 'MaxMind\\Db\\Reader\\Util' => __DIR__ . '/..' . '/maxmind-db/reader/src/MaxMind/Db/Reader/Util.php',
86
+ 'MaxMind\\Exception\\AuthenticationException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/AuthenticationException.php',
87
+ 'MaxMind\\Exception\\HttpException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/HttpException.php',
88
+ 'MaxMind\\Exception\\InsufficientFundsException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/InsufficientFundsException.php',
89
+ 'MaxMind\\Exception\\InvalidInputException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/InvalidInputException.php',
90
+ 'MaxMind\\Exception\\InvalidRequestException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/InvalidRequestException.php',
91
+ 'MaxMind\\Exception\\IpAddressNotFoundException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/IpAddressNotFoundException.php',
92
+ 'MaxMind\\Exception\\PermissionRequiredException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/PermissionRequiredException.php',
93
+ 'MaxMind\\Exception\\WebServiceException' => __DIR__ . '/..' . '/maxmind/web-service-common/src/Exception/WebServiceException.php',
94
+ 'MaxMind\\WebService\\Client' => __DIR__ . '/..' . '/maxmind/web-service-common/src/WebService/Client.php',
95
+ 'MaxMind\\WebService\\Http\\CurlRequest' => __DIR__ . '/..' . '/maxmind/web-service-common/src/WebService/Http/CurlRequest.php',
96
+ 'MaxMind\\WebService\\Http\\Request' => __DIR__ . '/..' . '/maxmind/web-service-common/src/WebService/Http/Request.php',
97
+ 'MaxMind\\WebService\\Http\\RequestFactory' => __DIR__ . '/..' . '/maxmind/web-service-common/src/WebService/Http/RequestFactory.php',
98
+ );
99
+
100
  public static function getInitializer(ClassLoader $loader)
101
  {
102
  return \Closure::bind(function () use ($loader) {
103
  $loader->prefixLengthsPsr4 = ComposerStaticInite354937679ffa734a3f63544e59103dd::$prefixLengthsPsr4;
104
  $loader->prefixDirsPsr4 = ComposerStaticInite354937679ffa734a3f63544e59103dd::$prefixDirsPsr4;
105
+ $loader->classMap = ComposerStaticInite354937679ffa734a3f63544e59103dd::$classMap;
106
 
107
  }, null, ClassLoader::class);
108
  }
views/client-ip.php CHANGED
@@ -1,7 +1,7 @@
1
  <div class="wrap geoip-detect-wrap">
2
  <!-- This page cannot be translated yet, as I am not sure how it will look like in the long-term.
3
  The goal is to have wizard helping to set all the relevant options semi-automatically. -->
4
- <h1><?php _e('GeoIP Detection', 'geoip-detect');?> - Client IP Debug Panel</h1>
5
  <p>
6
  <a href="tools.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>"><?php _e('Test IP Detection Lookup', 'geoip-detect')?></a>
7
  |
1
  <div class="wrap geoip-detect-wrap">
2
  <!-- This page cannot be translated yet, as I am not sure how it will look like in the long-term.
3
  The goal is to have wizard helping to set all the relevant options semi-automatically. -->
4
+ <h1><?php _e('Geolocation IP Detection', 'geoip-detect');?> - Client IP Debug Panel</h1>
5
  <p>
6
  <a href="tools.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>"><?php _e('Test IP Detection Lookup', 'geoip-detect')?></a>
7
  |
views/lookup.php CHANGED
@@ -33,7 +33,7 @@ function var_export_short($data, $return=true)
33
 
34
  ?>
35
  <div class="wrap geoip-detect-wrap">
36
- <h1><?php _e('GeoIP Detection', 'geoip-detect');?></h1>
37
  <p>
38
  <a href="options-general.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>"><?php _e('Options', 'geoip-detect');?></a>
39
  </p>
@@ -150,7 +150,7 @@ function var_export_short($data, $return=true)
150
  case 'shortcode':
151
  $extra = '';
152
  if (!empty($_POST['locales']) && $key_2 === 'name') {
153
- $extra .= ' lang="' . $_POST['locales'] . '"';
154
  }
155
  if (!empty($_POST['skip_cache'])) {
156
  $extra .= ' skip_cache="true"';
@@ -162,7 +162,16 @@ function var_export_short($data, $return=true)
162
  case 'js':
163
  $prop = '"' . $key_1 . '.' . $key_2 . '"';
164
  if (!empty($_POST['locales']) && $key_2 === 'name') {
165
- $access = 'record.get_with_locales(' . $prop . ', ' . json_encode(explode(',', $_POST['locales'])) . ')';
 
 
 
 
 
 
 
 
 
166
  } else {
167
  $access = 'record.get(' . $prop . ')';
168
  }
33
 
34
  ?>
35
  <div class="wrap geoip-detect-wrap">
36
+ <h1><?php _e('Geolocation IP Detection', 'geoip-detect');?></h1>
37
  <p>
38
  <a href="options-general.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>"><?php _e('Options', 'geoip-detect');?></a>
39
  </p>
150
  case 'shortcode':
151
  $extra = '';
152
  if (!empty($_POST['locales']) && $key_2 === 'name') {
153
+ $extra .= ' lang="' . esc_attr($_POST['locales']) . '"';
154
  }
155
  if (!empty($_POST['skip_cache'])) {
156
  $extra .= ' skip_cache="true"';
162
  case 'js':
163
  $prop = '"' . $key_1 . '.' . $key_2 . '"';
164
  if (!empty($_POST['locales']) && $key_2 === 'name') {
165
+ $locales_to_js = array(
166
+ 'en' => '"en"',
167
+ 'fr,en' => '["fr", "en"]',
168
+ );
169
+ if (isset($locales_to_js[$_POST['locales']])) {
170
+ $locales_js = $locales_to_js[$_POST['locales']];
171
+ } else {
172
+ $locales_js = 'NULL';
173
+ }
174
+ $access = 'record.get_with_locales(' . $prop . ', ' . $locales_js . ')';
175
  } else {
176
  $access = 'record.get(' . $prop . ')';
177
  }
views/options.php CHANGED
@@ -4,7 +4,7 @@ $currentSourceId = $currentSource->getId();
4
  ?>
5
 
6
  <div class="wrap">
7
- <h1><?php _e('GeoIP Detection', 'geoip-detect');?></h1>
8
  <p><a href="tools.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>"><?php _e('Test IP Detection Lookup', 'geoip-detect')?></a></p>
9
  <?php if (!empty($message)): ?>
10
  <p class="geoip_detect_error">
@@ -91,7 +91,7 @@ $currentSourceId = $currentSource->getId();
91
  </span>
92
  </p>
93
  <p>
94
- <label><?php _e('IPs of trusted proxies:', 'geoip-detect'); ?><input type="text" name="options[trusted_proxy_ips]" <?php echo esc_attr($wp_options['trusted_proxy_ips']); ?>" placeholder="1.1.1.1, 1234::1, 2.2.2.2/24" />
95
  <span class="detail-box">
96
  <?php _e('If specified, only IPs in this list will be treated as proxy.', 'geoip-detect'); ?><br>
97
  <?php _e('Make sure to add both IPv4 and IPv6 adresses of the proxy!', 'geoip-detect'); ?>
4
  ?>
5
 
6
  <div class="wrap">
7
+ <h1><?php _e('Geolocation IP Detection', 'geoip-detect');?></h1>
8
  <p><a href="tools.php?page=<?php echo GEOIP_PLUGIN_BASENAME ?>"><?php _e('Test IP Detection Lookup', 'geoip-detect')?></a></p>
9
  <?php if (!empty($message)): ?>
10
  <p class="geoip_detect_error">
91
  </span>
92
  </p>
93
  <p>
94
+ <label><?php _e('IPs of trusted proxies:', 'geoip-detect'); ?><input type="text" name="options[trusted_proxy_ips]" value="<?php echo esc_attr($wp_options['trusted_proxy_ips']); ?>" placeholder="1.1.1.1, 1234::1, 2.2.2.2/24" />
95
  <span class="detail-box">
96
  <?php _e('If specified, only IPs in this list will be treated as proxy.', 'geoip-detect'); ?><br>
97
  <?php _e('Make sure to add both IPv4 and IPv6 adresses of the proxy!', 'geoip-detect'); ?>
yarn.lock CHANGED
@@ -1062,7 +1062,7 @@ babel-plugin-syntax-class-properties@^6.8.0:
1062
  resolved "https://registry.yarnpkg.com/babel-plugin-syntax-class-properties/-/babel-plugin-syntax-class-properties-6.13.0.tgz#d7eb23b79a317f8543962c505b827c7d6cac27de"
1063
  integrity sha1-1+sjt5oxf4VDlixQW4J8fWysJ94=
1064
 
1065
- babel-plugin-transform-class-properties@>=6.24.1:
1066
  version "6.24.1"
1067
  resolved "https://registry.yarnpkg.com/babel-plugin-transform-class-properties/-/babel-plugin-transform-class-properties-6.24.1.tgz#6a79763ea61d33d36f37b611aa9def81a81b46ac"
1068
  integrity sha1-anl2PqYdM9NvN7YRqp3vgagbRqw=
1062
  resolved "https://registry.yarnpkg.com/babel-plugin-syntax-class-properties/-/babel-plugin-syntax-class-properties-6.13.0.tgz#d7eb23b79a317f8543962c505b827c7d6cac27de"
1063
  integrity sha1-1+sjt5oxf4VDlixQW4J8fWysJ94=
1064
 
1065
+ babel-plugin-transform-class-properties@^6.24.1:
1066
  version "6.24.1"
1067
  resolved "https://registry.yarnpkg.com/babel-plugin-transform-class-properties/-/babel-plugin-transform-class-properties-6.24.1.tgz#6a79763ea61d33d36f37b611aa9def81a81b46ac"
1068
  integrity sha1-anl2PqYdM9NvN7YRqp3vgagbRqw=