Skip to content

Commit

Permalink
release: 1.1.3 (#236)
Browse files Browse the repository at this point in the history
  • Loading branch information
devxb authored Jan 11, 2025
2 parents 52d3c5a + 2e30e21 commit 3e07e62
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ class GuildController(
@PathVariable("guildId") guildId: Long,
) = leaveGuildFacade.leave(token, guildId)

@GetMapping("/guilds/{guildId}/draw")
@GetMapping(value = ["/guilds/{guildId}/draw"], produces = ["image/svg+xml"])
fun draw(
@PathVariable("guildId") guildId: Long,
) = drawGuildFacade.drawGuild(guildId)
Expand Down
3 changes: 2 additions & 1 deletion src/main/kotlin/org/gitanimals/guild/domain/Guild.kt
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,8 @@ class Guild(
fun getLeaderUserId(): Long = leader.userId

fun accept(acceptUserId: Long) {
val acceptUser = waitMembers.firstOrNull { it.userId == acceptUserId } ?: return
val acceptUser = waitMembers.firstOrNull { it.userId == acceptUserId }
?: throw IllegalArgumentException("Cannot find waitMember by userId: \"$acceptUserId\"")
waitMembers.remove(acceptUser)

members.add(acceptUser.toMember())
Expand Down

0 comments on commit 3e07e62

Please sign in to comment.