mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
优化安装流程
This commit is contained in:
1 parent
63d55cedf4
commit
508f5644c3
30 files changed
+279
-139
No files matched your search
+3
-3
@@ -10,9 +10,9 @@ mongourl += `${options.host}:${options.port}/${options.name}`;
|
||||
*/
|
||||
let db = null;
|
||||
Mongo.MongoClient.connect(mongourl, { useNewUrlParser: true, useUnifiedTopology: true })
|
||||
.then((Database) => {
|
||||
db = Database.db(options.name);
|
||||
db.Db = Database;
|
||||
.then((Client) => {
|
||||
db = Client.db(options.name);
|
||||
db.Client = Client;
|
||||
bus.publish('system_database_connected', null);
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user