firebase / firebase/quickstart-nodejs

config/index.js does not exit after executing

Đang mở
#183 2 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
JavaScript
Star
933
Fork
425
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

When I run "node config/index.js get", it was actually executed successfully, but it does not exit.
Shall we need to add "finally" block like the following?
```node.js
function getTemplate() {
const config = admin.remoteConfig();
config.getTemplate()
.then(template => {
console.log('ETag from server: ' + template.etag);
const templateStr = JSON.stringify(template, null, 2);
fs.writeFileSync('config.json', templateStr);
})
.catch(err => {
console.error('Unable to get template');
console.error(err);
}).finally(() => {
process.exit();
});
}
```

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.