From 09ded37d9163dcb9ad29e364b596f6da4d462fbd Mon Sep 17 00:00:00 2001 From: Michael Barrett <991592+mike182uk@users.noreply.github.com> Date: Thu, 1 Jun 2023 12:11:01 +0100 Subject: [PATCH] Removed emailErrors flag (#16900) refs https://github.com/TryGhost/Team/issues/3337 Removed emailErrors flag as it is no longer needed --- ghost/admin/app/services/feature.js | 1 - ghost/admin/app/templates/settings/labs.hbs | 13 ------------- .../utils/serializers/output/mappers/emails.js | 8 -------- ghost/core/core/shared/labs.js | 1 - .../admin/__snapshots__/settings.test.js.snap | 2 +- 5 files changed, 1 insertion(+), 24 deletions(-) diff --git a/ghost/admin/app/services/feature.js b/ghost/admin/app/services/feature.js index f9d2d3bb53..a1ced049eb 100644 --- a/ghost/admin/app/services/feature.js +++ b/ghost/admin/app/services/feature.js @@ -64,7 +64,6 @@ export default class FeatureService extends Service { @feature('lexicalMultiplayer') lexicalMultiplayer; @feature('audienceFeedback') audienceFeedback; @feature('webmentions') webmentions; - @feature('emailErrors') emailErrors; @feature('websockets') websockets; @feature('stripeAutomaticTax') stripeAutomaticTax; @feature('makingItRain') makingItRain; diff --git a/ghost/admin/app/templates/settings/labs.hbs b/ghost/admin/app/templates/settings/labs.hbs index b1c3670bd1..e2edf28800 100644 --- a/ghost/admin/app/templates/settings/labs.hbs +++ b/ghost/admin/app/templates/settings/labs.hbs @@ -228,19 +228,6 @@ -
-
-
-

Show email errors

-

- This makes email errors visible in the UI. -

-
-
- -
-
-
diff --git a/ghost/core/core/server/api/endpoints/utils/serializers/output/mappers/emails.js b/ghost/core/core/server/api/endpoints/utils/serializers/output/mappers/emails.js index 1bd9f49697..27476bc4e8 100644 --- a/ghost/core/core/server/api/endpoints/utils/serializers/output/mappers/emails.js +++ b/ghost/core/core/server/api/endpoints/utils/serializers/output/mappers/emails.js @@ -1,5 +1,3 @@ -const labs = require('../../../../../../../shared/labs'); -const config = require('../../../../../../../shared/config'); const emailService = require('../../../../../../services/email-service'); module.exports = (model, frame) => { @@ -19,12 +17,6 @@ module.exports = (model, frame) => { } } - if (!labs.isSet('emailErrors') && !!(config.get('bulkEmail') && config.get('bulkEmail').mailgun)) { - if (jsonModel.status === 'failed') { - jsonModel.status = 'submitted'; - } - } - // Removed loaded post relation if set delete jsonModel.post; diff --git a/ghost/core/core/shared/labs.js b/ghost/core/core/shared/labs.js index 52ef05d11b..dd8b01a286 100644 --- a/ghost/core/core/shared/labs.js +++ b/ghost/core/core/shared/labs.js @@ -17,7 +17,6 @@ const messages = { const GA_FEATURES = [ 'audienceFeedback', 'themeErrorsNotification', - 'emailErrors', 'outboundLinkTagging', 'announcementBar' ]; diff --git a/ghost/core/test/e2e-api/admin/__snapshots__/settings.test.js.snap b/ghost/core/test/e2e-api/admin/__snapshots__/settings.test.js.snap index 39aabe2ce5..b5e678c2db 100644 --- a/ghost/core/test/e2e-api/admin/__snapshots__/settings.test.js.snap +++ b/ghost/core/test/e2e-api/admin/__snapshots__/settings.test.js.snap @@ -718,7 +718,7 @@ exports[`Settings API Edit Can edit a setting 2: [headers] 1`] = ` Object { "access-control-allow-origin": "http://127.0.0.1:2369", "cache-control": "no-cache, private, no-store, must-revalidate, max-stale=0, post-check=0, pre-check=0", - "content-length": "4014", + "content-length": "3993", "content-type": "application/json; charset=utf-8", "content-version": StringMatching /v\\\\d\\+\\\\\\.\\\\d\\+/, "etag": StringMatching /\\(\\?:W\\\\/\\)\\?"\\(\\?:\\[ !#-\\\\x7E\\\\x80-\\\\xFF\\]\\*\\|\\\\r\\\\n\\[\\\\t \\]\\|\\\\\\\\\\.\\)\\*"/,