diff --git a/CHANGELOG.md b/CHANGELOG.md index 9e912cc46..ade2b31e0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,7 @@ - Fix a bug: event, space, training or machine main image on description page is deformed on small devices - Fix a bug: profile completion of non SSO-imported users trigger a fuzzy email - Fix a bug: creation of negative credits +- Fix a bug: unable to display profiles of users whom any reservation is associated with a deleted object - Updated test data to allow passing test suite - [TODO DEPLOY] `rake db:migrate` diff --git a/app/views/api/members/show.json.jbuilder b/app/views/api/members/show.json.jbuilder index 7f417dffe..9074edbe3 100644 --- a/app/views/api/members/show.json.jbuilder +++ b/app/views/api/members/show.json.jbuilder @@ -61,7 +61,7 @@ json.training_reservations @member.reservations.where(reservable_type: 'Training json.start_at r.slots.first.start_at json.end_at r.slots.first.end_at json.reservable r.reservable - json.is_valid @member.training_ids.include?(r.reservable.id) + json.is_valid @member.training_ids.include?(r.reservable_id) json.canceled_at r.slots.first.canceled_at end json.training_credits @member.training_credits do |tc|