From: Nicolas Boisselier Date: Fri, 30 Aug 2024 15:34:30 +0000 (+0200) Subject: lib/php/db.php X-Git-Url: https://git.nbdom.net/?a=commitdiff_plain;h=4389c8a2aa17708d48b90dc9d7b18532b6ed60c8;p=nb.git lib/php/db.php --- diff --git a/lib/php/db.php b/lib/php/db.php index 7eba7704..f9a99eba 100644 --- a/lib/php/db.php +++ b/lib/php/db.php @@ -1159,12 +1159,13 @@ class Db extends nb { public function status() { $status = $new = []; + $server = isset( $_SERVER['SERVER_ADDR'] ) ? $_SERVER['SERVER_ADDR'] : 'localhost'; $new = [] +[ 'id' => (empty($this->id) ? '' : $this->id), 'name' => $this->name, 'type' => $this->type, - 'host' => $this->host, + 'host' => ($this->type == 'sqlite' ? $server.':' : '').$this->host, 'tables' => count($this->tables()), ] +($this->conf_type('use_path') ? [] : [