Converted posts tests to async/await syntax and updated tests

This commit is contained in:
Keith Holliday
2016-01-11 12:35:46 -06:00
parent f235010536
commit ffbd4696e3
3 changed files with 101 additions and 70 deletions
+1
View File
@@ -43,6 +43,7 @@ api.createGroup = {
user.balance--;
user.guilds.push(group._id);
} else {
if (group.privacy === 'public') throw new NotAuthorized(res.t('partyMustbePrivate'));
if (user.party._id) throw new NotAuthorized(res.t('messageGroupAlreadyInParty'));
user.party._id = group._id;