jasonlessenich / DIH4JDA

A fairly easy-to-use command framework for the Java Discord API, with support for Slash Commands and Context Commands
Apache License 2.0
17 stars 0 forks source link

Bump net.dv8tion:JDA from 5.0.1 to 5.0.2 #204

Closed dependabot[bot] closed 2 months ago

dependabot[bot] commented 2 months ago

Bumps net.dv8tion:JDA from 5.0.1 to 5.0.2.

Release notes

Sourced from net.dv8tion:JDA's releases.

v5.0.2 | Single time event listener

Overview

This release includes some bug fixes as well as a new event listener feature to add a one-time-use event listener.

Once Event Listener (#2683)

A common problem that developers run into, is "waiting" for a specific event in the context of some command. For instance, waiting for a user to add a reaction or reply with a message in response to some prompt.

This can now be achieved using the new listenOnce event listener:

// listen for a message event
jda.listenOnce(MessageReceivedEvent.class)
    // filter for specific event
    .filter(event -> event.getChannel().equals(channel))
    .filter(event -> event.getAuthor().equals(user))
    // handle timeout
    .timeout(timeout, () -> hook.editOriginal("Timeout!").queue())
    // subscribe to first event that matches filters
    .subscribe(event -> {
        hook.editOriginal("You sent: " + event.getMessage().getContentRaw()).queue();
    });

New Features

Changes

Bug Fixes

Full Changelog: https://github.com/discord-jda/JDA/compare/v5.0.1...v5.0.2

Installation

Gradle

repositories {
    mavenCentral()
</tr></table> 

... (truncated)

Commits


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)