Skip to content

Commit 5b20478

Browse files
authored
Merge pull request hestiacp#2230 from jaapmarcus/fix/float-issue-php
hestiacp#2229 Fix bug where php version incorrectly floated
2 parents e143c49 + 03d00ca commit 5b20478

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

web/inc/main.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
} else {
1616
define('JS_LATEST_UPDATE', 'r=' . time());
1717
}
18-
define('DEFAULT_PHP_VERSION', 'php-' . exec('php -r "echo (float)phpversion();"'));
18+
define('DEFAULT_PHP_VERSION', 'php-' . exec('php -r "echo substr(phpversion(),0,3);"'));
1919

2020
// Load Hestia Config directly
2121
load_hestia_config();
@@ -444,7 +444,6 @@ function backendtpl_with_webdomains()
444444
exec(HESTIA_CMD . 'v-list-web-domains '. escapeshellarg($user) . ' json', $output, $return_var);
445445
$domains = json_decode(implode('', $output), true);
446446
unset($output);
447-
448447
foreach ($domains as $domain => $domain_details) {
449448
if (!empty($domain_details['BACKEND'])) {
450449
$backend = $domain_details['BACKEND'];

0 commit comments

Comments
 (0)