Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix JDA#retrieveWebhookById #2319

Merged
merged 1 commit into from Nov 2, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/main/java/net/dv8tion/jda/api/JDA.java
Expand Up @@ -1838,6 +1838,7 @@ default JDA setRequiredScopes(@Nonnull String... scopes)

/**
* Retrieves a {@link net.dv8tion.jda.api.entities.Webhook Webhook} by its id.
* <br>If the webhook does not belong to any known guild of this JDA session, it will be {@link Webhook#isPartial() partial}.
*
* <p>Possible {@link net.dv8tion.jda.api.requests.ErrorResponse ErrorResponses} caused by
* the returned {@link net.dv8tion.jda.api.requests.RestAction RestAction} include the following:
Expand Down Expand Up @@ -1867,6 +1868,7 @@ default JDA setRequiredScopes(@Nonnull String... scopes)

/**
* Retrieves a {@link net.dv8tion.jda.api.entities.Webhook Webhook} by its id.
* <br>If the webhook does not belong to any known guild of this JDA session, it will be {@link Webhook#isPartial() partial}.
*
* <p>Possible {@link net.dv8tion.jda.api.requests.ErrorResponse ErrorResponses} caused by
* the returned {@link net.dv8tion.jda.api.requests.RestAction RestAction} include the following:
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/net/dv8tion/jda/internal/JDAImpl.java
Expand Up @@ -1014,7 +1014,7 @@ public RestAction<Webhook> retrieveWebhookById(@Nonnull String webhookId)
{
DataObject object = response.getObject();
EntityBuilder builder = getEntityBuilder();
return builder.createWebhook(object);
return builder.createWebhook(object, true);
});
}

Expand Down