Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dns: remove dns.promises experimental warning #26592

Merged
merged 3 commits into from
Mar 29, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/api/dns.md
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@ earlier ones time out or result in some other error.

## DNS Promises API

> Stability: 1 - Experimental
> Stability: 2 - Stable

The `dns.promises` API provides an alternative set of asynchronous DNS methods
that return `Promise` objects rather than using callbacks. The API is accessible
Expand Down
4 changes: 1 addition & 3 deletions lib/dns.js
Original file line number Diff line number Diff line change
Expand Up @@ -316,13 +316,11 @@ bindDefaultResolver(module.exports, getDefaultResolver());
Object.defineProperties(module.exports, {
promises: {
configurable: true,
enumerable: false,
enumerable: true,
get() {
if (promises === null) {
promises = require('internal/dns/promises');
promises.setServers = defaultResolverSetServers;
process.emitWarning('The dns.promises API is experimental',
'ExperimentalWarning');
}
return promises;
}
Expand Down
2 changes: 0 additions & 2 deletions test/parallel/test-dns-lookup.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ common.expectWarning({
'internal/test/binding': [
'These APIs are for internal testing only. Do not use them.'
],
// For dns.promises.
'ExperimentalWarning': 'The dns.promises API is experimental',
// For calling `dns.lookup` with falsy `hostname`.
'DeprecationWarning': {
DEP0118: 'The provided hostname "false" is not a valid ' +
Expand Down