Fix regexp for version input to accept rcX releases

pull/7051/head
Aleksander Machniak 5 years ago
parent b63d549834
commit 71bcf2e245

@ -29,7 +29,7 @@ $opts = rcube_utils::get_opt(array('v' => 'version', 'y' => 'accept:bool'));
if (!$opts['version']) {
echo "What version are you upgrading from? Type '?' if you don't know.\n";
if (($input = trim(fgets(STDIN))) && preg_match('/^[0-9.]+[a-z-]*$/', $input)) {
if (($input = trim(fgets(STDIN))) && preg_match('/^[0-9.]+[a-z0-9-]*$/', $input)) {
$opts['version'] = $input;
}
else {

Loading…
Cancel
Save