Skip to content
This repository was archived by the owner on Oct 19, 2018. It is now read-only.

Commit cfff355

Browse files
committed
fix: await init() of nodes in cubic.use()
1 parent 1aa0461 commit cfff355

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,10 +147,10 @@ class Cubic {
147147
if (group) {
148148
cubic.nodes[group] = cubic.nodes[group] || {}
149149
cubic.nodes[group][id] = node
150-
cubic.nodes[group][id].init()
150+
await cubic.nodes[group][id].init()
151151
} else {
152152
cubic.nodes[id] = node
153-
cubic.nodes[id].init()
153+
await cubic.nodes[id].init()
154154
}
155155
let name = group ? `${group} ${id}` : id
156156
let port = id === 'api' ? ` (Listening on :${node.config.provided.port || node.config.local.port})` : ''

0 commit comments

Comments
 (0)