mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-06 22:40:14 -05:00
🐛 Fixed member "last seen at" data not being returned in the API
refs c4470ff732
- labs flag was removed under the false assumption it was a client-side only flag but the `last_seen_at` property in API responses was also gated meaning the member details screen showed "Not seen yet" and the members list did not show the last seen date of all members when filtering
This commit is contained in:
parent
9ff8d7f910
commit
0cc147ae2d
3 changed files with 2 additions and 8 deletions
|
@ -124,13 +124,10 @@ function serializeMember(member, options) {
|
|||
email_opened_count: json.email_opened_count,
|
||||
email_open_rate: json.email_open_rate,
|
||||
email_recipients: json.email_recipients,
|
||||
status: json.status
|
||||
status: json.status,
|
||||
last_seen_at: json.last_seen_at
|
||||
};
|
||||
|
||||
if (labs.isSet('membersLastSeenFilter')) {
|
||||
serialized.last_seen_at = json.last_seen_at;
|
||||
}
|
||||
|
||||
if (json.products) {
|
||||
serialized.products = json.products;
|
||||
}
|
||||
|
|
|
@ -14,7 +14,6 @@ describe('Legacy Members API', function () {
|
|||
|
||||
beforeEach(function () {
|
||||
mockManager.mockLabsDisabled('multipleProducts');
|
||||
mockManager.mockLabsEnabled('membersLastSeenFilter');
|
||||
});
|
||||
|
||||
afterEach(function () {
|
||||
|
|
|
@ -53,7 +53,6 @@ describe('Members API without Stripe', function () {
|
|||
});
|
||||
|
||||
beforeEach(function () {
|
||||
mockManager.mockLabsEnabled('membersLastSeenFilter');
|
||||
mockManager.mockMail();
|
||||
});
|
||||
|
||||
|
@ -91,7 +90,6 @@ describe('Members API', function () {
|
|||
|
||||
beforeEach(function () {
|
||||
mockManager.mockLabsEnabled('multipleProducts');
|
||||
mockManager.mockLabsEnabled('membersLastSeenFilter');
|
||||
mockManager.mockStripe();
|
||||
mockManager.mockMail();
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue