diff --git a/src/grom.gleam b/src/grom.gleam index 3520755..0a70966 100644 --- a/src/grom.gleam +++ b/src/grom.gleam @@ -668,7 +668,7 @@ fn new_request( } fn handle_response( - response: Response(String), + response response: Response(String), decode_with decoder: Decoder(a), ) -> Result(a, RestError) { response @@ -815,7 +815,7 @@ pub fn get_current_user_request(token token: Token) -> Request(String) { pub fn get_current_user_response( response: Response(String), ) -> Result(User, RestError) { - handle_response(response, decode_with: user_decoder()) + handle_response(response:, decode_with: user_decoder()) } pub fn get_user_request( @@ -832,7 +832,7 @@ pub fn get_user_request( pub fn get_user_response( response: Response(String), ) -> Result(User, RestError) { - handle_response(response, decode_with: user_decoder()) + handle_response(response:, decode_with: user_decoder()) } /// This type is used to diffrentiate between the ways of modifying an object. @@ -903,7 +903,7 @@ pub fn modify_current_user_request( pub fn modify_current_user_response( response: Response(String), ) -> Result(User, RestError) { - handle_response(response, decode_with: user_decoder()) + handle_response(response:, decode_with: user_decoder()) } pub fn new_modify_current_user() -> ModifyCurrentUser { @@ -1379,7 +1379,7 @@ pub fn get_current_user_as_guild_member_request( pub fn get_current_user_as_guild_member_response( response: Response(String), ) -> Result(GuildMember, RestError) { - handle_response(response, decode_with: guild_member_decoder()) + handle_response(response:, decode_with: guild_member_decoder()) } pub fn leave_guild_request( @@ -5952,7 +5952,7 @@ pub fn get_guild_request( pub fn get_guild_response( response: Response(String), ) -> Result(Guild, RestError) { - handle_response(response, decode_with: guild_decoder()) + handle_response(response:, decode_with: guild_decoder()) } fn guild_approximate_counts_decoder() -> Decoder(GuildApproximateCounts) { @@ -5987,7 +5987,7 @@ pub fn get_guild_with_counts( pub fn get_guild_with_counts_response( response: Response(String), ) -> Result(#(Guild, GuildApproximateCounts), RestError) { - handle_response(response, decode_with: { + handle_response(response:, decode_with: { use guild <- decode.then(guild_decoder()) use counts <- decode.then(guild_approximate_counts_decoder()) decode.success(#(guild, counts)) @@ -6071,7 +6071,7 @@ pub fn get_guild_preview_request( pub fn get_guild_preview_response( response: Response(String), ) -> Result(GuildPreview, RestError) { - handle_response(response, decode_with: guild_preview_decoder()) + handle_response(response:, decode_with: guild_preview_decoder()) } /// Look into the `(new_)modify_guild_*` functions to use this type using a builder pattern. @@ -6692,7 +6692,7 @@ pub fn modify_guild_request( pub fn modify_guild_response( response: Response(String), ) -> Result(Guild, RestError) { - handle_response(response, decode_with: guild_decoder()) + handle_response(response:, decode_with: guild_decoder()) } fn dm_channel_decoder() -> Decoder(DmChannel) { @@ -6849,7 +6849,7 @@ pub fn new_announcement_channel_request( pub fn new_announcement_channel_response( response: Response(String), ) -> Result(AnnouncementChannel, RestError) { - handle_response(response, decode_with: announcement_channel_decoder()) + handle_response(response:, decode_with: announcement_channel_decoder()) } /// Requires the `AllowManagingChannels` permission. @@ -6959,7 +6959,7 @@ pub fn new_text_channel_request( pub fn new_text_channel_response( response: Response(String), ) -> Result(TextChannel, RestError) { - handle_response(response, decode_with: text_channel_decoder()) + handle_response(response:, decode_with: text_channel_decoder()) } /// Requires the `AllowManagingChannels` permission. @@ -7111,7 +7111,7 @@ pub fn new_voice_channel_request( pub fn new_voice_channel_response( response: Response(String), ) -> Result(VoiceChannel, RestError) { - handle_response(response, decode_with: voice_channel_decoder()) + handle_response(response:, decode_with: voice_channel_decoder()) } pub fn new_voice_channel(named name: String) -> CreateVoiceChannel { @@ -7252,7 +7252,7 @@ pub fn new_category_channel_request( pub fn new_category_channel_response( response: Response(String), ) -> Result(CategoryChannel, RestError) { - handle_response(response, decode_with: category_channel_decoder()) + handle_response(response:, decode_with: category_channel_decoder()) } pub fn new_category_channel(named name: String) -> CreateCategoryChannel { @@ -7343,7 +7343,7 @@ pub fn new_stage_channel_request( pub fn new_stage_channel_response( response: Response(String), ) -> Result(StageChannel, RestError) { - handle_response(response, decode_with: stage_channel_decoder()) + handle_response(response:, decode_with: stage_channel_decoder()) } pub fn new_stage_channel(named name: String) -> CreateStageChannel { @@ -7531,7 +7531,7 @@ pub fn new_forum_channel_request( pub fn new_forum_channel_response( response: Response(String), ) -> Result(ForumChannel, RestError) { - handle_response(response, decode_with: forum_channel_decoder()) + handle_response(response:, decode_with: forum_channel_decoder()) } pub fn new_forum_channel(named name: String) -> CreateForumChannel { @@ -7728,7 +7728,7 @@ pub fn new_media_channel_request( pub fn new_media_channel_response( response: Response(String), ) -> Result(MediaChannel, RestError) { - handle_response(response, decode_with: media_channel_decoder()) + handle_response(response:, decode_with: media_channel_decoder()) } pub fn new_media_channel(named name: String) -> CreateMediaChannel { @@ -7995,7 +7995,7 @@ pub fn get_guild_member_request( pub fn get_guild_member_response( response: Response(String), ) -> Result(GuildMember, RestError) { - handle_response(response, decode_with: guild_member_decoder()) + handle_response(response:, decode_with: guild_member_decoder()) } pub opaque type GetGuildMembersOptions { @@ -8295,7 +8295,7 @@ pub fn modify_guild_member_request( pub fn modify_guild_member_response( response: Response(String), ) -> Result(GuildMember, RestError) { - handle_response(response, decode_with: guild_member_decoder()) + handle_response(response:, decode_with: guild_member_decoder()) } pub opaque type ModifyCurrentGuildMember { @@ -8403,7 +8403,7 @@ pub fn modify_current_guild_member_request( pub fn modify_current_guild_member_response( response: Response(String), ) -> Result(GuildMember, RestError) { - handle_response(response, decode_with: guild_member_decoder()) + handle_response(response:, decode_with: guild_member_decoder()) } /// Requires the `AllowManagingRoles` permission. @@ -8563,7 +8563,7 @@ pub fn get_guild_bans_request( pub fn get_guild_bans_response( response: Response(String), ) -> Result(List(GuildBan), RestError) { - handle_response(response, decode_with: decode.list(of: guild_ban_decoder())) + handle_response(response:, decode_with: decode.list(of: guild_ban_decoder())) } /// Requires the `AllowBanningMembers` permission. @@ -8585,7 +8585,7 @@ pub fn get_guild_ban_request( pub fn get_guild_ban_response( response: Response(String), ) -> Result(GuildBan, RestError) { - handle_response(response, decode_with: guild_ban_decoder()) + handle_response(response:, decode_with: guild_ban_decoder()) } /// Requires the `AllowBanningMembers` permission. @@ -8700,7 +8700,7 @@ pub fn bulk_guild_ban_request( pub fn bulk_guild_ban_response( response: Response(String), ) -> Result(BulkGuildBanResponse, RestError) { - handle_response(response, decode_with: bulk_guild_ban_response_decoder()) + handle_response(response:, decode_with: bulk_guild_ban_response_decoder()) } pub fn get_guild_roles_request( @@ -8717,7 +8717,7 @@ pub fn get_guild_roles_request( pub fn get_guild_roles_response( response: Response(String), ) -> Result(List(Role), RestError) { - handle_response(response, decode_with: decode.list(of: role_decoder())) + handle_response(response:, decode_with: decode.list(of: role_decoder())) } pub fn get_role_request( @@ -8738,7 +8738,7 @@ pub fn get_role_request( pub fn get_role_response( response: Response(String), ) -> Result(Role, RestError) { - handle_response(response, decode_with: role_decoder()) + handle_response(response:, decode_with: role_decoder()) } /// Returns a Dict of (role_id, member_count) @@ -8901,7 +8901,7 @@ pub fn new_role_request( pub fn new_role_response( response: Response(String), ) -> Result(Role, RestError) { - handle_response(response, decode_with: role_decoder()) + handle_response(response:, decode_with: role_decoder()) } /// See the [`move_role`](#move_role) and [`delete_role_position`](#delete_role_position) functions. @@ -8960,7 +8960,7 @@ pub fn modify_role_positions_request( pub fn modify_role_position_response( response: Response(String), ) -> Result(List(Role), RestError) { - handle_response(response, decode_with: decode.list(of: role_decoder())) + handle_response(response:, decode_with: decode.list(of: role_decoder())) } pub opaque type ModifyRole { @@ -9095,7 +9095,7 @@ pub fn modify_role_request( pub fn modify_role_response( response: Response(String), ) -> Result(Role, RestError) { - handle_response(response, decode_with: role_decoder()) + handle_response(response:, decode_with: role_decoder()) } /// Requires the `AllowManagingRoles` permission. @@ -9874,7 +9874,7 @@ pub fn get_guild_invites_request( pub fn get_guild_invites_response( response: Response(String), ) -> Result(List(Invite), RestError) { - handle_response(response, decode_with: decode.list(of: invite_decoder())) + handle_response(response:, decode_with: decode.list(of: invite_decoder())) } /// Discord has some integrations with YouTube/Twitch for member/subscriber-only guilds. @@ -10186,7 +10186,7 @@ pub fn get_guild_widget_settings_request( pub fn get_guild_widget_settings_response( response: Response(String), ) -> Result(GuildWidgetSettings, RestError) { - handle_response(response, decode_with: guild_widget_settings_decoder()) + handle_response(response:, decode_with: guild_widget_settings_decoder()) } pub opaque type ModifyGuildWidgetSettings { @@ -10256,7 +10256,7 @@ pub fn modify_guild_widget_settings_request( pub fn modify_guild_widget_settings_response( response: Response(String), ) -> Result(GuildWidgetSettings, RestError) { - handle_response(response, decode_with: guild_widget_settings_decoder()) + handle_response(response:, decode_with: guild_widget_settings_decoder()) } pub type GuildWidget { @@ -10402,7 +10402,7 @@ pub fn get_guild_widget_request( pub fn get_guild_widget_response( response: Response(String), ) -> Result(GuildWidget, RestError) { - handle_response(response, decode_with: guild_widget_decoder()) + handle_response(response:, decode_with: guild_widget_decoder()) } pub type GuildVanityInvite { @@ -10445,7 +10445,7 @@ pub fn get_guild_vanity_invite_request( pub fn get_guild_vanity_invite_response( response: Response(String), ) -> Result(Option(GuildVanityInvite), RestError) { - handle_response(response, decode_with: guild_vanity_invite_decoder()) + handle_response(response:, decode_with: guild_vanity_invite_decoder()) } /// Requires the `AllowManagingGuild` permission if the welcome screen is disabled. @@ -10463,7 +10463,7 @@ pub fn get_guild_welcome_screen_request( pub fn get_guild_welcome_screen_response( response: Response(String), ) -> Result(GuildWelcomeScreen, RestError) { - handle_response(response, decode_with: guild_welcome_screen_decoder()) + handle_response(response:, decode_with: guild_welcome_screen_decoder()) } pub opaque type ModifyGuildWelcomeScreen { @@ -10550,7 +10550,7 @@ pub fn modify_guild_welcome_screen_request( pub fn modify_guild_welcome_screen_response( response: Response(String), ) -> Result(GuildWelcomeScreen, RestError) { - handle_response(response, decode_with: guild_welcome_screen_decoder()) + handle_response(response:, decode_with: guild_welcome_screen_decoder()) } pub type GuildOnboarding { @@ -10710,7 +10710,7 @@ pub fn get_guild_onboarding_request( pub fn get_guild_onboarding_response( response: Response(String), ) -> Result(GuildOnboarding, RestError) { - handle_response(response, decode_with: guild_onboarding_decoder()) + handle_response(response:, decode_with: guild_onboarding_decoder()) } // Modify Guild Onboarding was left unimplemented here due to doubts as to whether one has to reuse prompts or if they can be created @@ -10803,7 +10803,7 @@ pub fn modify_guild_incidents_data_request( pub fn modify_guild_incidents_data_response( response: Response(String), ) -> Result(GuildIncidentsData, RestError) { - handle_response(response, decode_with: guild_incidents_data_decoder()) + handle_response(response:, decode_with: guild_incidents_data_decoder()) } /// Do not use this endpoint as means of notifying everyone in a server about something. @@ -10827,7 +10827,7 @@ pub fn new_dm_channel_request( pub fn new_dm_channel_response( response: Response(String), ) -> Result(DmChannel, RestError) { - handle_response(response, decode_with: dm_channel_decoder()) + handle_response(response:, decode_with: dm_channel_decoder()) } pub fn get_channel_request( @@ -10844,7 +10844,7 @@ pub fn get_channel_request( pub fn get_channel_response( response: Response(String), ) -> Result(Channel, RestError) { - handle_response(response, decode_with: channel_decoder()) + handle_response(response:, decode_with: channel_decoder()) } fn channel_decoder() -> Decoder(Channel) { @@ -11087,14 +11087,14 @@ pub fn modify_text_channel_request( pub fn modify_text_channel_response( response: Response(String), ) -> Result(TextChannel, RestError) { - handle_response(response, decode_with: text_channel_decoder()) + handle_response(response:, decode_with: text_channel_decoder()) } /// Use this if you converted the text channel to an announcement channel. pub fn modify_text_channel_with_conversion_response( response: Response(String), ) -> Result(AnnouncementChannel, RestError) { - handle_response(response, decode_with: announcement_channel_decoder()) + handle_response(response:, decode_with: announcement_channel_decoder()) } pub opaque type ModifyVoiceChannel { @@ -11291,7 +11291,7 @@ pub fn modify_voice_channel_request( pub fn modify_voice_channel_response( response: Response(String), ) -> Result(VoiceChannel, RestError) { - handle_response(response, decode_with: voice_channel_decoder()) + handle_response(response:, decode_with: voice_channel_decoder()) } pub opaque type ModifyCategoryChannel { @@ -11371,7 +11371,7 @@ pub fn modify_category_channel_request( pub fn modify_category_channel_response( response: Response(String), ) -> Result(CategoryChannel, RestError) { - handle_response(response, decode_with: category_channel_decoder()) + handle_response(response:, decode_with: category_channel_decoder()) } pub opaque type ModifyAnnouncementChannel { @@ -11438,14 +11438,14 @@ pub fn modify_announcement_channel_request( pub fn modify_announcement_channel_response( response: Response(String), ) -> Result(AnnouncementChannel, RestError) { - handle_response(response, decode_with: announcement_channel_decoder()) + handle_response(response:, decode_with: announcement_channel_decoder()) } /// Use this if you converted the announcement channel to a text channel. pub fn modify_announcement_channel_with_conversion_response( response: Response(String), ) -> Result(TextChannel, RestError) { - handle_response(response, decode_with: text_channel_decoder()) + handle_response(response:, decode_with: text_channel_decoder()) } pub fn new_modify_announcement_channel() -> ModifyAnnouncementChannel { @@ -11749,7 +11749,7 @@ pub fn modify_stage_channel_request( pub fn modify_stage_channel_response( response: Response(String), ) -> Result(StageChannel, RestError) { - handle_response(response, decode_with: stage_channel_decoder()) + handle_response(response:, decode_with: stage_channel_decoder()) } pub opaque type ModifyForumChannel { @@ -12017,7 +12017,7 @@ pub fn modify_forum_channel_request( pub fn modify_forum_channel_response( response: Response(String), ) -> Result(ForumChannel, RestError) { - handle_response(response, decode_with: forum_channel_decoder()) + handle_response(response:, decode_with: forum_channel_decoder()) } pub opaque type ModifyMediaChannel { @@ -12271,7 +12271,7 @@ pub fn modify_media_channel_request( pub fn modify_media_channel_response( response: Response(String), ) -> Result(MediaChannel, RestError) { - handle_response(response, decode_with: media_channel_decoder()) + handle_response(response:, decode_with: media_channel_decoder()) } pub opaque type ModifyThread { @@ -12421,7 +12421,7 @@ pub fn modify_thread_request( pub fn modify_thread_response( response: Response(String), ) -> Result(Thread, RestError) { - handle_response(response, decode_with: thread_decoder()) + handle_response(response:, decode_with: thread_decoder()) } fn rate_limit_per_user_decoder() -> Decoder(RateLimitPerUser) { @@ -12525,7 +12525,7 @@ pub fn get_guild_channel_invites_request( pub fn get_guild_channel_invites_response( response: Response(String), ) -> Result(List(Invite), RestError) { - handle_response(response, decode_with: decode.list(of: invite_decoder())) + handle_response(response:, decode_with: decode.list(of: invite_decoder())) } pub opaque type CreateGuildChannelInvite { @@ -12727,7 +12727,7 @@ pub fn follow_announcement_channel_request( pub fn follow_announcement_channel_response( response: Response(String), ) -> Result(FollowedChannel, RestError) { - handle_response(response, decode_with: followed_channel_decoder()) + handle_response(response:, decode_with: followed_channel_decoder()) } /// The typing indicator expires after 10 seconds. @@ -12830,7 +12830,7 @@ pub fn new_thread_from_message_request( pub fn new_thread_from_message_response( response: Response(String), ) -> Result(Thread, RestError) { - handle_response(response, decode_with: thread_decoder()) + handle_response(response:, decode_with: thread_decoder()) } pub opaque type CreateThread { @@ -15146,7 +15146,7 @@ pub fn get_thread_member_request( pub fn get_thread_member_response( response: Response(String), ) -> Result(ThreadMember, RestError) { - handle_response(response, decode_with: thread_member_decoder()) + handle_response(response:, decode_with: thread_member_decoder()) } pub fn get_thread_member_with_guild_member_request( @@ -15167,7 +15167,7 @@ pub fn get_thread_member_with_guild_member_response( decode.success(#(thread_member, guild_member)) } - handle_response(response, decode_with: decoder) + handle_response(response:, decode_with: decoder) } /// Requires that your app has the `GUILD_MEMBERS` priviledged intent enabled. @@ -15213,7 +15213,7 @@ pub fn get_message_request( pub fn get_message_response( response: Response(String), ) -> Result(Message, RestError) { - handle_response(response, decode_with: message_decoder()) + handle_response(response:, decode_with: message_decoder()) } pub opaque type CreateMessage { @@ -15720,7 +15720,7 @@ pub fn crosspost_message_request( pub fn crosspost_message_response( response: Response(String), ) -> Result(Message, RestError) { - handle_response(response, decode_with: message_decoder()) + handle_response(response:, decode_with: message_decoder()) } pub type MessageReactionEmoji { @@ -15895,7 +15895,7 @@ pub fn get_reacting_users_request( pub fn get_reacting_users_response( response: Response(String), ) -> Result(List(User), RestError) { - handle_response(response, decode_with: decode.list(of: user_decoder())) + handle_response(response:, decode_with: decode.list(of: user_decoder())) } /// Removes all reactions from a message. @@ -16271,7 +16271,7 @@ fn message_pin_decoder() -> Decoder(MessagePin) { pub fn get_channel_pins_response( response: Response(String), ) -> Result(GetChannelPinsResponse, RestError) { - handle_response(response, decode_with: get_channel_pins_response_decoder()) + handle_response(response:, decode_with: get_channel_pins_response_decoder()) } /// Requires the `AllowPinningMessages` permission. @@ -16336,7 +16336,7 @@ pub fn get_application_skus_request( pub fn get_application_skus_response( response: Response(String), ) -> Result(List(Sku), RestError) { - handle_response(response, decode_with: decode.list(sku_decoder())) + handle_response(response:, decode_with: decode.list(sku_decoder())) } pub opaque type GetPollAnswerVotersOptions { @@ -16429,7 +16429,7 @@ pub fn end_poll_request( pub fn end_poll_response( response: Response(String), ) -> Result(Message, RestError) { - handle_response(response, decode_with: message_decoder()) + handle_response(response:, decode_with: message_decoder()) } pub fn get_sticker_request( @@ -16446,7 +16446,7 @@ pub fn get_sticker_request( pub fn get_sticker_response( response: Response(String), ) -> Result(Sticker, RestError) { - handle_response(response, decode_with: sticker_decoder()) + handle_response(response:, decode_with: sticker_decoder()) } pub fn get_sticker_packs_request(token token: Token) -> Request(String) { @@ -16479,7 +16479,7 @@ pub fn get_sticker_pack_request( pub fn get_sticker_pack_response( response: Response(String), ) -> Result(StickerPack, RestError) { - handle_response(response, decode_with: sticker_pack_decoder()) + handle_response(response:, decode_with: sticker_pack_decoder()) } /// The returned stickers will contain the `user` field if the bot has the `AllowCreatingGuildExpressions` @@ -16524,7 +16524,7 @@ pub fn get_guild_sticker_request( pub fn get_guild_sticker_response( response: Response(String), ) -> Result(GuildSticker, RestError) { - handle_response(response, decode_with: guild_sticker_decoder()) + handle_response(response:, decode_with: guild_sticker_decoder()) } pub opaque type CreateGuildSticker { @@ -16670,7 +16670,7 @@ pub fn modify_guild_sticker_request( pub fn modify_guild_sticker_response( response: Response(String), ) -> Result(GuildSticker, RestError) { - handle_response(response, decode_with: guild_sticker_decoder()) + handle_response(response:, decode_with: guild_sticker_decoder()) } /// Required permissions: @@ -16706,7 +16706,7 @@ pub fn get_current_application_request(token token: Token) -> Request(String) { pub fn get_current_application_response( response: Response(String), ) -> Result(Application, RestError) { - handle_response(response, decode_with: application_decoder()) + handle_response(response:, decode_with: application_decoder()) } pub opaque type ModifyCurrentApplication { @@ -17052,7 +17052,7 @@ pub fn modify_current_application_request( pub fn modify_current_application_response( response: Response(String), ) -> Result(Application, RestError) { - handle_response(response, decode_with: application_decoder()) + handle_response(response:, decode_with: application_decoder()) } pub type SoundboardSound { @@ -17231,7 +17231,7 @@ pub fn get_guild_soundboard_sound_request( pub fn get_guild_soundboard_sound_response( response: Response(String), ) -> Result(SoundboardSound, RestError) { - handle_response(response, decode_with: soundboard_sound_decoder()) + handle_response(response:, decode_with: soundboard_sound_decoder()) } pub type SoundboardSoundContentType { @@ -17323,7 +17323,7 @@ pub fn new_guild_soundboard_sound_request( pub fn new_guild_soundboard_sound_response( response: Response(String), ) -> Result(SoundboardSound, RestError) { - handle_response(response, decode_with: soundboard_sound_decoder()) + handle_response(response:, decode_with: soundboard_sound_decoder()) } pub opaque type ModifyGuildSoundboardSound { @@ -17397,7 +17397,7 @@ pub fn modify_guild_soundboard_sound_request( pub fn modify_guild_soundboard_sound_response( response: Response(String), ) -> Result(SoundboardSound, RestError) { - handle_response(response, decode_with: soundboard_sound_decoder()) + handle_response(response:, decode_with: soundboard_sound_decoder()) } fn modify_guild_soundboard_sound_to_json( @@ -17506,7 +17506,7 @@ pub fn get_stage_instance_request( pub fn get_stage_channel_response( response: Response(String), ) -> Result(StageInstance, RestError) { - handle_response(response, decode_with: stage_instance_decoder()) + handle_response(response:, decode_with: stage_instance_decoder()) } pub opaque type CreateStageInstance { @@ -17583,7 +17583,7 @@ pub fn new_stage_instance_request( pub fn new_stage_instance_response( response: Response(String), ) -> Result(StageInstance, RestError) { - handle_response(response, decode_with: stage_instance_decoder()) + handle_response(response:, decode_with: stage_instance_decoder()) } pub fn delete_stage_instance_request( @@ -17702,7 +17702,7 @@ pub fn get_current_user_voice_state_request( pub fn get_current_user_voice_state_response( response: Response(String), ) -> Result(VoiceState, RestError) { - handle_response(response, decode_with: voice_state_decoder()) + handle_response(response:, decode_with: voice_state_decoder()) } /// If the user is connected to a voice channel, @@ -17725,7 +17725,7 @@ pub fn get_user_voice_state_request( pub fn get_user_voice_state_response( response: Response(String), ) -> Result(VoiceState, RestError) { - handle_response(response, decode_with: voice_state_decoder()) + handle_response(response:, decode_with: voice_state_decoder()) } /// An "entitlement" is something a user gets access to by purchasing an @@ -18046,7 +18046,10 @@ pub fn get_current_application_entitlements_request( pub fn get_current_application_entitlements_response( response: Response(String), ) -> Result(List(Entitlement), RestError) { - handle_response(response, decode_with: decode.list(of: entitlement_decoder())) + handle_response( + response:, + decode_with: decode.list(of: entitlement_decoder()), + ) } /// You have to provide the current application's ID. Sorry, I don't make the rules :/ @@ -18068,7 +18071,7 @@ pub fn get_entitlement_request( pub fn get_entitlement_response( response: Response(String), ) -> Result(Entitlement, RestError) { - handle_response(response, decode_with: entitlement_decoder()) + handle_response(response:, decode_with: entitlement_decoder()) } /// Marks the entitlement as consumed by the user. @@ -18193,5 +18196,5 @@ pub fn get_sku_subscription_request( pub fn get_sku_subscription_response( response: Response(String), ) -> Result(Subscription, RestError) { - handle_response(response, decode_with: subscription_decoder()) + handle_response(response:, decode_with: subscription_decoder()) }