diff --git a/app/main/model/mapmodel.php b/app/main/model/mapmodel.php index 9d5a4c94..6e14b0da 100644 --- a/app/main/model/mapmodel.php +++ b/app/main/model/mapmodel.php @@ -377,13 +377,13 @@ class MapModel extends AbstractMapTrackingModel { $valid = true; if( !empty($val) ){ $hosts = [ - 'slack' => 'hooks.slack.com', - 'discord' => 'discordapp.com' + 'slack' => ['hooks.slack.com'], + 'discord' => ['discordapp.com', 'ptb.discordapp.com'] ]; if( !\Audit::instance()->url($val) || - parse_url($val, PHP_URL_HOST) !== $hosts[$type] + !in_array(parse_url($val, PHP_URL_HOST), $hosts[$type]) ){ $valid = false; $this->throwValidationException($key); diff --git a/public/templates/dialog/map.html b/public/templates/dialog/map.html index 30f96d3d..8358f3d6 100644 --- a/public/templates/dialog/map.html +++ b/public/templates/dialog/map.html @@ -227,7 +227,7 @@
- +