Ghost/core
Naz cc71bbfd61 Hooked up api version compatibility middleware
refs https://github.com/TryGhost/Toolbox/issues/280

- ctd of putting pieces together to allow Ghost notifying owner and admin users about version mismatch errors
-  The `@tryghost/mw-api-version-mismatch` in a combination with api version compatibility service make the whole notification process play nicely :)
- The flow of the logic from the request to a sent notification email is following:
1. Request comes is with an Accept-Version header that's behind current Ghost version and is not supported
2. mw-error-handler middleware's 'resourceNotFound' detects such request and returns a 406 with a special 'code' identifying if the version of the client is ahead or behind
3. mw-api-version-mismatch intercepts the 406 request with "code === 'UPDATE_CLIENT'` and calls up APIVersionCompatibilityService
4. emails are sent out to active owner and admin users

- The above flow is also illustratd in the e2e tests that come with the changeset
2022-04-22 16:31:56 +08:00
..
client@d0daa084ac Updated Admin to v4.44.0 2022-04-15 16:00:39 +01:00
frontend Moved cors middleware to own file 2022-04-19 11:19:59 +01:00
server Hooked up api version compatibility middleware 2022-04-22 16:31:56 +08:00
shared Added multiple newsletters UI feature flag 2022-04-22 12:40:51 +05:30
app.js Fixed express app stacking 2021-12-06 21:28:53 +13:00
boot.js Hooked up api version compatibility service 2022-04-22 16:31:56 +08:00
bridge.js 💡 Pinned frontend API version to canary 2022-02-17 17:55:55 +00:00