0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-03 23:00:14 -05:00
ghost/core/server
Fabien 'egg' O'Carroll 1294e3f92c
Replaced all usage of member models with members-api (#12117)
no-issue

* Added stripeSubscriptions relation to member model

This allows us to fetch the subscriptions for a member via standard
model usage, e.g. `withRelated: ['stripeSubscriptions']` rather than
offloading to loops and `decorateWithSubscriptions` functions, this is
more performant and less non-standard than the existing method.

* Updated serialize methods to match existing format

The current usage of `decorateWithSubscriptions` and the usage of
members throughout the codebase has a subscriptions array on a stripe
object on the member, this ensures that when we serialize members to
JSON that we are using the same format.

There is definitely room to change this in future, but this is an
attempt to create as few breaking changes as possible.

* Installed @tryghost/members-api@0.26.0

This includes the required API changes so that everywhere can use
members-api directly rather than models and/or helper methods
2020-08-12 14:17:44 +01:00
..
adapters Replaced constants file with @tryghost/constants 2020-08-11 12:51:16 +01:00
api Replaced all usage of member models with members-api (#12117) 2020-08-12 14:17:44 +01:00
data Extracted promise libs and history into @tryghost/promise 2020-08-11 18:44:21 +01:00
lib Extracted promise libs and history into @tryghost/promise 2020-08-11 18:44:21 +01:00
models Replaced all usage of member models with members-api (#12117) 2020-08-12 14:17:44 +01:00
public
services Replaced all usage of member models with members-api (#12117) 2020-08-12 14:17:44 +01:00
translations Added an additional log to notify shutdown start 2020-08-10 14:53:05 +01:00
views
web Added job-manager & wired up shutdown and testmode 2020-08-11 21:31:34 +01:00
analytics-events.js
ghost-server.js Added job-manager & wired up shutdown and testmode 2020-08-11 21:31:34 +01:00
index.js Added job-manager & wired up shutdown and testmode 2020-08-11 21:31:34 +01:00
overrides.js
update-check.js