0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-06 22:40:14 -05:00
ghost/test
Kevin Ansfield 21ac7bb0f7
Fixed ETag header for admin templates not changing between versions (#13695)
refs https://github.com/TryGhost/Team/issues/1175
backports https://github.com/TryGhost/Ghost/pull/13680

We found the ETag header sent when serving the Admin template for /ghost/ was not changing between versions which after an upgrade could result in out of date cached content being served containing links to JS/CSS files that no longer existed.

The culprit is weak etags served by Node's `send` package, coupled with Admin template filesize not changing between versions and `npm pack` setting a fixed modification date for every file. See pillarjs/send#176 for more details.

- updated the Admin app's controller to read the template and generate an md5 hash of the contents so we can serve a strong ETag header value when serving the `/ghost/` html
2021-10-28 12:07:13 +01:00
..
api-acceptance Fixed test after adding forceUpgrade to config properties 2021-10-25 10:02:11 +02:00
frontend-acceptance Refactored acceptance tests to use async-await 2020-12-03 08:47:01 +00:00
regression Fixed ETag header for admin templates not changing between versions (#13695) 2021-10-28 12:07:13 +01:00
unit Updated {{content}} helper partial template name 2021-02-09 14:05:49 +05:30
utils Fixed ETag header for admin templates not changing between versions (#13695) 2021-10-28 12:07:13 +01:00
.eslintignore
.eslintrc.json Enabled error for "no-shadow" eslint rule 2020-10-27 11:27:37 +13:00
.jshintrc