From 63dc87e7e33964f6980ed8945b4a34c7daed7248 Mon Sep 17 00:00:00 2001 From: joyqi Date: Tue, 17 Aug 2021 18:39:46 +0800 Subject: [PATCH] fix cli --- install.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install.php b/install.php index bf08aae2..8a0b240f 100644 --- a/install.php +++ b/install.php @@ -110,7 +110,7 @@ function install_get_default_options(): array { 'commentsRequireModeration' => 0, 'plugins' => 'a:0:{}', 'commentDateFormat' => 'F jS, Y \a\t h:i a', - 'siteUrl' => install_get_site_url(), + 'siteUrl' => install_is_cli() ? 'http://localhost' : install_get_site_url(), 'defaultCategory' => 1, 'allowRegister' => 0, 'defaultAllowComment' => 1, @@ -303,7 +303,7 @@ function install_raise_error($error, $config = null) { if (install_is_cli()) { if (is_array($error)) { foreach ($error as $key => $value) { - echo (is_int($key) ? '' : $key . ': ') . $value; + echo (is_int($key) ? '' : $key . ': ') . $value . "\n"; } } else { echo $error;