Skip to content

Commit

Permalink
fixing stuff
Browse files Browse the repository at this point in the history
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
  • Loading branch information
ArtificialOwl committed Aug 1, 2018
1 parent bd517f1 commit a377935
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Service/CirclesService.php
Original file line number Diff line number Diff line change
Expand Up @@ -564,11 +564,11 @@ public function checkThatCircleIsNotFull(Circle $circle) {
if ($limit === -1) {
return;
}
if ($limit === 0) {
if ($limit === 0 || $limit === '' || $limit === null) {
$limit = $this->configService->getAppValue(ConfigService::CIRCLES_MEMBERS_LIMIT);
}

if (sizeof($members) >= $limit) {
if (sizeof($members) >= $limit) {
throw new MembersLimitException(
'This circle already reach its limit on the number of members'
);
Expand Down
1 change: 1 addition & 0 deletions tests/unit/lib/Api/CirclesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -702,6 +702,7 @@ public function testJoinCircleAndLeave() {
$member->getCircleId()
]
);
} catch (MemberDoesNotExistException $e) {
} catch (Exception $e) {
throw $e;
}
Expand Down

0 comments on commit a377935

Please sign in to comment.