diff --git a/packages/react-native-bots/dangerfile.js b/packages/react-native-bots/dangerfile.js index c14203e4c458d4..0a14b4d0fc2bb0 100644 --- a/packages/react-native-bots/dangerfile.js +++ b/packages/react-native-bots/dangerfile.js @@ -60,19 +60,21 @@ if (!includesTestPlan && !isFromPhabricator) { } // Check if there is a changelog and validate it -const status = validateChangelog(danger.github.pr.body); -const changelogInstructions = - 'See Changelog format'; -if (status === 'missing') { - // Provides advice if a changelog is missing - const title = ':clipboard: Missing Changelog'; - const idea = - 'Please add a Changelog to your PR description. ' + changelogInstructions; - fail(`${title} - ${idea}`); -} else if (status === 'invalid') { - const title = ':clipboard: Verify Changelog Format'; - const idea = changelogInstructions; - fail(`${title} - ${idea}`); +if (!isFromPhabricator) { + const status = validateChangelog(danger.github.pr.body); + const changelogInstructions = + 'See Changelog format'; + if (status === 'missing') { + // Provides advice if a changelog is missing + const title = ':clipboard: Missing Changelog'; + const idea = + 'Please add a Changelog to your PR description. ' + changelogInstructions; + fail(`${title} - ${idea}`); + } else if (status === 'invalid') { + const title = ':clipboard: Verify Changelog Format'; + const idea = changelogInstructions; + fail(`${title} - ${idea}`); + } } // Warns if the PR is opened against stable, as commits need to be cherry picked and tagged by a release maintainer.