Skip to content

Commit

Permalink
Add missing showCaptionAboveMedia to sendVideo
Browse files Browse the repository at this point in the history
  • Loading branch information
aNNiMON authored and rubenlagus committed Jul 6, 2024
1 parent 19267bb commit ef735ea
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ public CompletableFuture<Message> executeAsync(SendVideo sendVideo) {
.addPart(SendVideo.HEIGHT_FIELD, sendVideo.getHeight())
.addPart(SendVideo.HAS_SPOILER_FIELD, sendVideo.getHasSpoiler())
.addPart(SendVideo.BUSINESS_CONNECTION_ID_FIELD, sendVideo.getBusinessConnectionId())
.addPart(SendVideo.SHOW_CAPTION_ABOVE_MEDIA_FIELD, sendVideo.getShowCaptionAboveMedia())
.addJsonPart(SendVideo.CAPTION_ENTITIES_FIELD, sendVideo.getCaptionEntities());

if (sendVideo.getThumbnail() != null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ public class SendVideo extends SendMediaBotMethod<Message> {
public static final String CAPTION_ENTITIES_FIELD = "caption_entities";
public static final String HAS_SPOILER_FIELD = "has_spoiler";
public static final String BUSINESS_CONNECTION_ID_FIELD = "business_connection_id";
public static final String SHOW_CAPTION_ABOVE_MEDIA_FIELD = "show_caption_above_media";

@NonNull
private String chatId; ///< Unique identifier for the chat to send the message to (Or username for channels)
Expand Down Expand Up @@ -109,6 +110,11 @@ public class SendVideo extends SendMediaBotMethod<Message> {
* Unique identifier of the message effect to be added to the message
*/
private String messageEffectId;
/**
* Optional.
* Pass True, if the caption must be shown above the message media
*/
private Boolean showCaptionAboveMedia;

@Tolerate
public void setChatId(@NonNull Long chatId) {
Expand Down

0 comments on commit ef735ea

Please sign in to comment.