@@ -1540,7 +1540,7 @@ public Mono<Boolean> existsInvite(long guildId, String inviteCreator, String inv
1540
1540
* @param inviteCode the Code of the Invite.
1541
1541
*/
1542
1542
public void removeInvite (long guildId , String inviteCode ) {
1543
- deleteEntityInternally ( getInvite (guildId , inviteCode ));
1543
+ getInvite (guildId , inviteCode ). subscribe ( x -> x . ifPresent ( this :: deleteEntityInternally ));
1544
1544
}
1545
1545
1546
1546
/**
@@ -1600,7 +1600,7 @@ public Mono<Optional<Invite>> getInvite(long guildId, long inviteCreator, String
1600
1600
* @param inviteCode the Code of the Invite.
1601
1601
*/
1602
1602
public void removeInvite (long guildId , long inviteCreator , String inviteCode ) {
1603
- deleteEntityInternally ( getInvite (guildId , inviteCreator , inviteCode ));
1603
+ getInvite (guildId , inviteCreator , inviteCode ). subscribe ( x -> x . ifPresent ( this :: deleteEntityInternally ));
1604
1604
}
1605
1605
1606
1606
/**
@@ -1612,7 +1612,7 @@ public void removeInvite(long guildId, long inviteCreator, String inviteCode) {
1612
1612
* @param inviteUsage the usage count of the Invite.
1613
1613
*/
1614
1614
public void removeInvite (long guildId , long inviteCreator , String inviteCode , long inviteUsage ) {
1615
- deleteEntityInternally ( getInvite (guildId , inviteCreator , inviteCode , inviteUsage ));
1615
+ getInvite (guildId , inviteCreator , inviteCode , inviteUsage ). subscribe ( x -> x . ifPresent ( this :: deleteEntityInternally ));
1616
1616
}
1617
1617
1618
1618
/**
@@ -2075,7 +2075,7 @@ public void addBirthday(long guildId, long channelId, long userId, String birthd
2075
2075
* @param userId the ID of the User.
2076
2076
*/
2077
2077
public void removeBirthday (long guildId , long userId ) {
2078
- getEntity (new BirthdayWish (), "FROM BirthdayWish WHERE guildId=:gid AND userId=:uid" , Map .of ("gid" , guildId , "uid" , userId )).subscribe (this ::deleteEntityInternally );
2078
+ getEntity (new BirthdayWish (), "FROM BirthdayWish WHERE guildId=:gid AND userId=:uid" , Map .of ("gid" , guildId , "uid" , userId )).subscribe (x -> x . ifPresent ( this ::deleteEntityInternally ) );
2079
2079
}
2080
2080
2081
2081
/**
0 commit comments