Emails: fix inverted DNS requirements notice condition (DOTEMP-76) - #113886
Merged
Conversation
The `has_wpcom_nameservers` guard was negated, so the external-nameserver warning was hidden for domains that actually needed it and shown for domains already on WordPress.com nameservers. Invert the condition so the notice appears only when the domain uses external nameservers. Fixes DOTEMP-76 Co-authored-by: matticbot <matticbot@users.noreply.github.com>
|
WordPress.com
Automattic for Agencies
|
|
This PR does not affect the size of JS and CSS bundles shipped to the user's browser. |
jordesign
marked this pull request as ready for review
August 28, 2026 02:28
Contributor
|
Tested that this causes correct behaviour for both domains using dotcom nameservers, and those using external namesevers. |
|
|
||
| export const DnsRequirementsNotice = ( { domainName, domainData }: DnsRequirementsNoticeProps ) => { | ||
| if ( ! domainData.has_wpcom_nameservers ) { | ||
| if ( domainData.has_wpcom_nameservers ) { |
Contributor
There was a problem hiding this comment.
Deferring this to @Automattic/quake
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Fixes DOTEMP-76
Proposed Changes
has_wpcom_nameserversguard inDnsRequirementsNoticeso the external-nameserver warning is shown when the domain uses external nameservers (i.e.has_wpcom_nameservers === false) and hidden when WordPress.com nameservers are already in use.DOMAIN_CONNECTIONsubtype variant).Why are these changes being made?
The condition
if (!has_wpcom_nameservers) return nullwas inverted: it suppressed the DNS warning exactly for the users who needed it (external nameservers) and displayed it incorrectly for users already on WordPress.com nameservers. The one-character change (!removed) restores the intended behavior.Testing Instructions
has_wpcom_nameservers: false).has_wpcom_nameservers: true).Pre-merge Checklist
Linear: DOTEMP-76
Co-authored-by: jordesign jordan.gillman@automattic.com