Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/roundcube/roundcubemail.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Hillmann <Project0@users.noreply.github.com>2018-01-07 10:47:59 +0300
committerAleksander Machniak <alec@alec.pl>2018-01-07 10:52:49 +0300
commitb9c038ca63c2413789e123ed4e04bba889b9f830 (patch)
tree15d72987e487c2913cd9758ccd4ef056cbca7c04 /program
parent55ba3501025af679400516babe123348b79d21f3 (diff)
Fix preg_match in guess_type function (#6123)
Diffstat (limited to 'program')
-rw-r--r--program/lib/Roundcube/rcube_config.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/program/lib/Roundcube/rcube_config.php b/program/lib/Roundcube/rcube_config.php
index a5f6a4ee5..431b512a3 100644
--- a/program/lib/Roundcube/rcube_config.php
+++ b/program/lib/Roundcube/rcube_config.php
@@ -109,13 +109,13 @@ class rcube_config
// array requires hint to be passed.
- if (preg_match('/^[-+]?(\d+(\.\d*)?|\.\d+)([eE][-+]?\d+)?$/', $value) !== false) {
+ if (preg_match('/^[-+]?(\d+(\.\d*)?|\.\d+)([eE][-+]?\d+)?$/', $value)) {
$type = 'double';
}
- else if (preg_match('/^\d+$/', $value) !== false) {
+ else if (preg_match('/^\d+$/', $value)) {
$type = 'integer';
}
- else if (preg_match('/(t(rue)?)|(f(alse)?)/i', $value) !== false) {
+ else if (preg_match('/^(t(rue)?)|(f(alse)?)$/i', $value)) {
$type = 'boolean';
}