Set invites to be an empty array if missing

This commit is contained in:
Shane Kilkelly 2016-08-15 15:22:23 +01:00
parent 40cb7e4590
commit 36d969e6e6

View file

@ -15,7 +15,10 @@ module.exports = ProjectEditorHandler =
deletedByExternalDataSource : project.deletedByExternalDataSource || false
deletedDocs: project.deletedDocs
members: []
invites: invites || []
invites: invites
if !result.invites?
result.invites = []
{owner, ownerFeatures, members} = @buildOwnerAndMembersViews(members)
result.owner = owner