0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-03 23:00:14 -05:00
ghost/test/unit/services
Kevin Ansfield 8a17e723a1 Moved usage of preview options from globalTemplateOptions to localTemplateOptions
refs https://github.com/TryGhost/Team/issues/1097

globalTemplateOptions are supposed to be static with localTemplateOptions being merged in per-request, however the per-request preview data was being extracted and set in the global options. Comments suggest that the global data should be static and eventually updated via other means, the usage of the request object to get per-request preview data is working against that.

- adjusted the preview handler to return an object rather than changing properties by reference on a passed in object
- moved preview data fetching out of `getSiteData()` used in `updateGlobalTemplateOptions()` and into `updateLocalTemplateOptions()` so that we're not relying on the request object in `updateGlobalTemplateOptions()`
2021-09-30 12:12:55 +01:00
..
apps Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
auth Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
mail 🔒 Fixed remote command injection when using sendmail email transport 2021-09-17 16:46:51 +01:00
mega 🐛 Fixed unsubscribed members receiving email when a post is sent to all members (#13181) 2021-07-26 12:47:03 +01:00
members Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
notifications Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
permissions Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
routing Divided f/e proxy into true proxy + rendering service 2021-09-29 13:10:14 +01:00
rss Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
settings Refactored ensure settings module into a class with DI 2021-09-29 20:56:55 +02:00
sitemap 🐛 Fixed error in sitemap with >50k posts (#13317) 2021-09-17 11:13:42 +01:00
theme-engine Moved usage of preview options from globalTemplateOptions to localTemplateOptions 2021-09-30 12:12:55 +01:00
themes Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
url Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
labs.test.js Fixed labs service unit tests 2021-09-14 10:19:26 +01:00
slack.test.js Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
xmlrpc.test.js Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00