Fix deprecation in Modal

This commit is contained in:
Vankka 2023-05-19 18:33:49 +03:00
parent 9d2ec71b39
commit 455065087c
No known key found for this signature in database
GPG Key ID: 6E50CB7A29B96AD0

View File

@ -79,7 +79,7 @@ public class Modal implements JDAEntity<net.dv8tion.jda.api.interactions.modals.
@Override
public net.dv8tion.jda.api.interactions.modals.Modal asJDA() {
return net.dv8tion.jda.api.interactions.modals.Modal.create(id, title)
.addActionRows(rows.stream().map(ActionRow::asJDA).collect(Collectors.toList()))
.addComponents(rows.stream().map(ActionRow::asJDA).collect(Collectors.toList()))
.build();
}