From b3d9c8f98932ce19301481597b6e4b54ceb4f031 Mon Sep 17 00:00:00 2001 From: Nikita Sinelnikov Date: Wed, 15 Dec 2021 16:40:25 +0200 Subject: [PATCH] - code review; - changed readme; --- includes/core/class-builtin.php | 1 - includes/core/class-validation.php | 6 +++--- readme.txt | 1 + 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/core/class-builtin.php b/includes/core/class-builtin.php index 5910a3f6..62f6c395 100644 --- a/includes/core/class-builtin.php +++ b/includes/core/class-builtin.php @@ -1025,7 +1025,6 @@ if ( ! class_exists( 'um\core\Builtin' ) ) { 'icon' => 'um-faicon-paper-plane', 'validate' => 'telegram_url', 'url_text' => 'Telegram', - 'advanced' => 'social', 'match' => 'https://t.me/', ), diff --git a/includes/core/class-validation.php b/includes/core/class-validation.php index 7eb44fb4..3589e691 100644 --- a/includes/core/class-validation.php +++ b/includes/core/class-validation.php @@ -285,7 +285,7 @@ if ( ! class_exists( 'um\core\Validation' ) ) { /** - * Is Discord ID + * Is Discord ID? * * @param $string * @@ -298,7 +298,7 @@ if ( ! class_exists( 'um\core\Validation' ) ) { if ( substr_count( $string, '#' ) > 1 ) { return false; } - if ( ! preg_match( '/(\S+)#(\d+)$/', trim( $string ) ) ) { + if ( ! preg_match( '/^(.+)#(\d+)$/', trim( $string ) ) ) { return false; } return true; @@ -417,4 +417,4 @@ if ( ! class_exists( 'um\core\Validation' ) ) { } } -} \ No newline at end of file +} diff --git a/readme.txt b/readme.txt index 94795d89..87ab6464 100644 --- a/readme.txt +++ b/readme.txt @@ -173,6 +173,7 @@ The plugin works with popular caching plugins by automatically excluding Ultimat - Fixed: Header meta for the Twitter Card. If the user has twitter field filled then will be filled by this value. - Fixed: Member directory a slider filter's label displaying. It uses the filled label for now. - Fixed: SkypeID field validation. Also all SkypeID fields on your forms changed type from `url` to `text`. SkypeID supports nicknames or https://join.skype.com/{hash} links. + - Fixed: Typos in Account > Privacy tab texts related to Download/Erase the user data. - Fixed: Some typos in the fields' labels. - Fixed: "false" display name in the member directory. It displays empty for now if the user hasn't display name. - Fixed: `UM()->clean_array()` function.