module PrivateParlorXT::AlbumHelpers

Direct including types

Defined in:

private-parlor-xt/album_helpers.cr

Constant Summary

WAIT_TIME = 500.milliseconds

Instance Method Summary

Instance Method Detail

def album_input(message : Tourmaline::Message, caption : String, entities : Array(Tourmaline::MessageEntity), allow_spoilers : Bool | Nil = false) : AlbumMedia | Nil #

Returns the Tourmaline::InputMedia from the media in the given message, if available.

Returns nil if there was no media in the message to create a Tourmaline::InputMedia


[View source]
def relay_album(albums : Hash(String, Album), album : String, message_id : MessageID, input : AlbumMedia, user : User, receivers : Array(UserID), reply_msids : Hash(UserID, ReplyParameters), effect : String | Nil, services : Services) : Nil #

Relays the given album after an arbitrary amount of time, waiting for the rest of the media group updates to come in

Returns early if the album is already queued for relaying, and adds the input to the Album object.


[View source]