discorb 0.6.0 → 0.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -64,6 +64,7 @@ module Discorb
64
64
  end
65
65
 
66
66
  alias fired_by target
67
+ alias from target
67
68
 
68
69
  def inspect
69
70
  "#<#{self.class} id=#{@id}>"
@@ -99,6 +100,9 @@ module Discorb
99
100
  #
100
101
  # Response with `DEFERRED_CHANNEL_MESSAGE_WITH_SOURCE`(`5`).
101
102
  #
103
+ # @macro async
104
+ # @macro http
105
+ #
102
106
  # @param [Boolean] ephemeral Whether to make the response ephemeral.
103
107
  #
104
108
  def defer_source(ephemeral: false)
@@ -116,6 +120,9 @@ module Discorb
116
120
  #
117
121
  # Response with `CHANNEL_MESSAGE_WITH_SOURCE`(`4`).
118
122
  #
123
+ # @macro async
124
+ # @macro http
125
+ #
119
126
  # @param [String] content The content of the response.
120
127
  # @param [Boolean] tts Whether to send the message as text-to-speech.
121
128
  # @param [Discorb::Embed] embed The embed to send.
@@ -125,45 +132,48 @@ module Discorb
125
132
  # @param [Boolean] ephemeral Whether to make the response ephemeral.
126
133
  #
127
134
  def post(content = nil, tts: false, embed: nil, embeds: nil, allowed_mentions: nil, components: nil, ephemeral: false)
128
- payload = {}
129
- payload[:content] = content if content
130
- payload[:tts] = tts
131
- tmp_embed = if embed
132
- [embed]
133
- elsif embeds
134
- embeds
135
- end
136
- payload[:embeds] = tmp_embed.map(&:to_hash) if tmp_embed
137
- payload[:allowed_mentions] = allowed_mentions ? allowed_mentions.to_hash(@client.allowed_mentions) : @client.allowed_mentions.to_hash
138
- if components
139
- tmp_components = []
140
- tmp_row = []
141
- components.each do |c|
142
- case c
143
- when Array
144
- tmp_components << tmp_row
145
- tmp_row = []
146
- tmp_components << c
147
- when SelectMenu
148
- tmp_components << tmp_row
149
- tmp_row = []
150
- tmp_components << [c]
151
- else
152
- tmp_row << c
135
+ Async do
136
+ payload = {}
137
+ payload[:content] = content if content
138
+ payload[:tts] = tts
139
+ tmp_embed = if embed
140
+ [embed]
141
+ elsif embeds
142
+ embeds
143
+ end
144
+ payload[:embeds] = tmp_embed.map(&:to_hash) if tmp_embed
145
+ payload[:allowed_mentions] = allowed_mentions ? allowed_mentions.to_hash(@client.allowed_mentions) : @client.allowed_mentions.to_hash
146
+ if components
147
+ tmp_components = []
148
+ tmp_row = []
149
+ components.each do |c|
150
+ case c
151
+ when Array
152
+ tmp_components << tmp_row
153
+ tmp_row = []
154
+ tmp_components << c
155
+ when SelectMenu
156
+ tmp_components << tmp_row
157
+ tmp_row = []
158
+ tmp_components << [c]
159
+ else
160
+ tmp_row << c
161
+ end
153
162
  end
163
+ tmp_components << tmp_row
164
+ payload[:components] = tmp_components.filter { |c| c.length.positive? }.map { |c| { type: 1, components: c.map(&:to_hash) } }
154
165
  end
155
- tmp_components << tmp_row
156
- payload[:components] = tmp_components.filter { |c| c.length.positive? }.map { |c| { type: 1, components: c.map(&:to_hash) } }
157
- end
158
- payload[:flags] = (ephemeral ? 1 << 6 : 0)
159
- if @responded
160
- @client.http.post("/webhooks/#{@id}/#{@token}", { type: 4, data: payload }).wait
161
- elsif @defered
162
- @client.http.post("/interactions/#{@id}/#{@token}/@original/edit", { type: 4, data: payload }).wait
163
- else
164
- @client.http.post("/interactions/#{@id}/#{@token}/callback", { type: 4, data: payload }).wait
166
+ payload[:flags] = (ephemeral ? 1 << 6 : 0)
167
+
168
+ if @responded
169
+ @client.http.post("/webhooks/#{@application_id}/#{@token}", payload).wait
170
+ elsif @defered
171
+ @client.http.patch("/webhooks/#{@application_id}/#{@token}/messages/@original", payload).wait
172
+ else
173
+ @client.http.post("/interactions/#{@id}/#{@token}/callback", { type: 4, data: payload }).wait
174
+ end
175
+ @responded = true
165
176
  end
166
- @responded = true
167
177
  end
168
178
  end
169
179
 
@@ -190,6 +200,9 @@ module Discorb
190
200
  #
191
201
  # Response with `UPDATE_MESSAGE`(`7`).
192
202
  #
203
+ # @macro async
204
+ # @macro http
205
+ #
193
206
  # @param [String] content The content of the response.
194
207
  # @param [Boolean] tts Whether to send the message as text-to-speech.
195
208
  # @param [Discorb::Embed] embed The embed to send.
@@ -199,38 +212,40 @@ module Discorb
199
212
  # @param [Boolean] ephemeral Whether to make the response ephemeral.
200
213
  #
201
214
  def edit(content, tts: false, embed: nil, embeds: nil, allowed_mentions: nil, components: nil, ephemeral: false)
202
- payload = {}
203
- payload[:content] = content if content
204
- payload[:tts] = tts
205
- tmp_embed = if embed
206
- [embed]
207
- elsif embeds
208
- embeds
209
- end
210
- payload[:embeds] = tmp_embed.map(&:to_hash) if tmp_embed
211
- payload[:allowed_mentions] = allowed_mentions ? allowed_mentions.to_hash(@client.allowed_mentions) : @client.allowed_mentions.to_hash
212
- if components
213
- tmp_components = []
214
- tmp_row = []
215
- components.each do |c|
216
- case c
217
- when Array
218
- tmp_components << tmp_row
219
- tmp_row = []
220
- tmp_components << c
221
- when SelectMenu
222
- tmp_components << tmp_row
223
- tmp_row = []
224
- tmp_components << [c]
225
- else
226
- tmp_row << c
215
+ Async do
216
+ payload = {}
217
+ payload[:content] = content if content
218
+ payload[:tts] = tts
219
+ tmp_embed = if embed
220
+ [embed]
221
+ elsif embeds
222
+ embeds
223
+ end
224
+ payload[:embeds] = tmp_embed.map(&:to_hash) if tmp_embed
225
+ payload[:allowed_mentions] = allowed_mentions ? allowed_mentions.to_hash(@client.allowed_mentions) : @client.allowed_mentions.to_hash
226
+ if components
227
+ tmp_components = []
228
+ tmp_row = []
229
+ components.each do |c|
230
+ case c
231
+ when Array
232
+ tmp_components << tmp_row
233
+ tmp_row = []
234
+ tmp_components << c
235
+ when SelectMenu
236
+ tmp_components << tmp_row
237
+ tmp_row = []
238
+ tmp_components << [c]
239
+ else
240
+ tmp_row << c
241
+ end
227
242
  end
243
+ tmp_components << tmp_row
244
+ payload[:components] = tmp_components.filter { |c| c.length.positive? }.map { |c| { type: 1, components: c.map(&:to_hash) } }
228
245
  end
229
- tmp_components << tmp_row
230
- payload[:components] = tmp_components.filter { |c| c.length.positive? }.map { |c| { type: 1, components: c.map(&:to_hash) } }
246
+ payload[:flags] = (ephemeral ? 1 << 6 : 0)
247
+ @client.http.post("/interactions/#{@id}/#{@token}/callback", { type: 6, data: payload }).wait
231
248
  end
232
- payload[:flags] = (ephemeral ? 1 << 6 : 0)
233
- @client.http.post("/interactions/#{@id}/#{@token}/callback", { type: 6, data: payload }).wait
234
249
  end
235
250
  end
236
251
 
data/lib/discorb/log.rb CHANGED
@@ -22,34 +22,34 @@ module Discorb
22
22
  raise ArgumentError, "Invalid log level: #{level}" unless @level
23
23
  end
24
24
 
25
- def debug(message)
25
+ def debug(message, fallback: nil)
26
26
  return unless @level <= 0
27
27
 
28
- write_output("DEBUG", "\e[90m", message)
28
+ write_output("DEBUG", "\e[90m", message, fallback)
29
29
  end
30
30
 
31
- def info(message)
31
+ def info(message, fallback: nil)
32
32
  return unless @level <= 1
33
33
 
34
- write_output("INFO", "\e[94m", message)
34
+ write_output("INFO", "\e[94m", message, fallback)
35
35
  end
36
36
 
37
- def warn(message)
37
+ def warn(message, fallback: nil)
38
38
  return unless @level <= 2
39
39
 
40
- write_output("WARN", "\e[93m", message)
40
+ write_output("WARN", "\e[93m", message, fallback)
41
41
  end
42
42
 
43
- def error(message)
43
+ def error(message, fallback: nil)
44
44
  return unless @level <= 3
45
45
 
46
- write_output("ERROR", "\e[31m", message)
46
+ write_output("ERROR", "\e[31m", message, fallback)
47
47
  end
48
48
 
49
- def fatal(message)
49
+ def fatal(message, fallback: nil)
50
50
  return unless @level <= 4
51
51
 
52
- write_output("FATAL", "\e[91m", message)
52
+ write_output("FATAL", "\e[91m", message, fallback)
53
53
  end
54
54
 
55
55
  class << self
@@ -58,8 +58,12 @@ module Discorb
58
58
 
59
59
  private
60
60
 
61
- def write_output(name, color, message)
62
- return unless @out
61
+ def write_output(name, color, message, fallback)
62
+ unless @out
63
+ fallback.puts(message) if fallback
64
+
65
+ return
66
+ end
63
67
 
64
68
  if @colorize_log
65
69
  @out.puts("\e[2;90m[#{Time.now.iso8601}] #{color}#{name}\e[m -- #{message}")
@@ -59,6 +59,8 @@ module Discorb
59
59
  # @!attribute [r] status
60
60
  # @macro client_cache
61
61
  # @return [Symbol] The status of the member. It's from the {#presence}.
62
+ # @!attribute [r] owner?
63
+ # @return [Boolean] Whether the member is the owner of the guild.
62
64
 
63
65
  # @!visibility private
64
66
  def initialize(client, guild_id, user_data, member_data)
@@ -99,18 +101,27 @@ module Discorb
99
101
  guild.voice_states[@id]
100
102
  end
101
103
 
104
+ def owner?
105
+ guild.owner_id == @id
106
+ end
107
+
102
108
  def guild
103
109
  @client.guilds[@guild_id]
104
110
  end
105
111
 
106
112
  def roles
107
- @role_ids.map { |r| guild.roles[r] }
113
+ @role_ids.map { |r| guild.roles[r] }.sort_by(&:position).reverse + [guild.roles[guild.id]]
108
114
  end
109
115
 
110
116
  def permissions
117
+ if owner?
118
+ return Permission.new((1 << 38) - 1)
119
+ end
111
120
  roles.map(&:permissions).sum(Permission.new(0))
112
121
  end
113
122
 
123
+ alias guild_permissions permissions
124
+
114
125
  def hoisted_role
115
126
  @hoisted_role_id && guild.roles[@hoisted_role_id]
116
127
  end
@@ -234,7 +245,7 @@ module Discorb
234
245
  @custom_avatar = member_data[:avatar] && Asset.new(member_data[:avatar])
235
246
  super(user_data)
236
247
  @display_avatar = @avatar || @custom_avatar
237
- @client.guilds[@guild_id].members[@id] = self unless @guild_id.nil?
248
+ @client.guilds[@guild_id].members[@id] = self unless @guild_id.nil? || @client.guilds[@guild_id].nil?
238
249
  @_member_data.update(member_data)
239
250
  end
240
251
  end
@@ -522,11 +522,11 @@ module Discorb
522
522
  if data[:member].nil? && data[:webhook_id]
523
523
  @webhook_id = Snowflake.new(data[:webhook_id])
524
524
  @author = Webhook::Message::Author.new(data[:author])
525
- elsif data[:guild_id].nil? || data[:guild_id].empty?
525
+ elsif data[:guild_id].nil? || data[:guild_id].empty? || data[:member].nil?
526
526
  @author = @client.users[data[:author][:id]] || User.new(@client, data[:author])
527
527
  else
528
- @author = guild.members[data[:author][:id]] || Member.new(@client,
529
- @guild_id, data[:author], data[:member])
528
+ @author = guild&.members&.get(data[:author][:id]) || Member.new(@client,
529
+ @guild_id, data[:author], data[:member])
530
530
  end
531
531
  @content = data[:content]
532
532
  @created_at = Time.iso8601(data[:timestamp])
data/lib/discorb.rb CHANGED
@@ -44,7 +44,7 @@ require_order = %w[common flag dictionary error rate_limit http intents emoji_ta
44
44
  %w[application audit_logs color components event] +
45
45
  %w[file guild_template image integration interaction invite log permission] +
46
46
  %w[presence reaction role sticker utils voice_state webhook] +
47
- %w[gateway_requests gateway command] +
47
+ %w[gateway_requests gateway app_command] +
48
48
  %w[asset extension client extend]
49
49
  require_order.each do |name|
50
50
  require_relative "discorb/#{name}.rb"
data/po/yard.pot CHANGED
@@ -322,7 +322,7 @@ msgid "## How do I register an application command?"
322
322
  msgstr ""
323
323
 
324
324
  #: ../docs/application_command.md:13
325
- msgid "Use {Discorb::Command::Handler#slash}, {Discorb::Command::Handler#group} for slash commands, {Discorb::Command::Handler#user_command} for user menu commands, and {Discorb::Command::Handler#message_command} for message menu commands."
325
+ msgid "Use {Discorb::ApplicationCommand::Handler#slash}, {Discorb::ApplicationCommand::Handler#group} for slash commands, {Discorb::ApplicationCommand::Handler#user_command} for user menu commands, and {Discorb::ApplicationCommand::Handler#message_command} for message menu commands."
326
326
  msgstr ""
327
327
 
328
328
  #: ../docs/application_command.md:15
@@ -349,7 +349,7 @@ msgid "client.slash(\"hello\", \"Greet for you\") do |interaction|\n"
349
349
  msgstr ""
350
350
 
351
351
  #: ../docs/application_command.md:36
352
- msgid "{Discorb::Command::Handler#slash} takes 5 arguments:"
352
+ msgid "{Discorb::ApplicationCommand::Handler#slash} takes 5 arguments:"
353
353
  msgstr ""
354
354
 
355
355
  #: ../docs/application_command.md:38
@@ -441,7 +441,7 @@ msgid "### Group Slash Commands"
441
441
  msgstr ""
442
442
 
443
443
  #: ../docs/application_command.md:104
444
- msgid "To register a group of slash commands, use {Discorb::Command::Handler#slash_group}."
444
+ msgid "To register a group of slash commands, use {Discorb::ApplicationCommand::Handler#slash_group}."
445
445
  msgstr ""
446
446
 
447
447
  #: ../docs/application_command.md:106
@@ -473,7 +473,7 @@ msgid "group.slash(\"bump_alert\", \"Whether bot should notify DISBOARD bump.\",
473
473
  msgstr ""
474
474
 
475
475
  #: ../docs/application_command.md:128
476
- msgid "You can make subcommand group by using {Discorb::Command::GroupCommand#group}."
476
+ msgid "You can make subcommand group by using {Discorb::ApplicationCommand::GroupCommand#group}."
477
477
  msgstr ""
478
478
 
479
479
  #: ../docs/application_command.md:130
@@ -558,7 +558,7 @@ msgid "```ruby\n"
558
558
  " interaction.post(\"Hello, #{user.name}!\")\n"
559
559
  "end\n"
560
560
  "```\n"
561
- "{Discorb::Command::Handler#user_command} takes 3 arguments:"
561
+ "{Discorb::ApplicationCommand::Handler#user_command} takes 3 arguments:"
562
562
  msgstr ""
563
563
 
564
564
  #: ../docs/application_command.md:216
@@ -595,7 +595,7 @@ msgid "```ruby\n"
595
595
  msgstr ""
596
596
 
597
597
  #: ../docs/application_command.md:238
598
- msgid "{Discorb::Command::Handler#message_command} takes 3 arguments:"
598
+ msgid "{Discorb::ApplicationCommand::Handler#message_command} takes 3 arguments:"
599
599
  msgstr ""
600
600
 
601
601
  #: ../docs/application_command.md:248
@@ -4592,7 +4592,7 @@ msgstr ""
4592
4592
  msgid "The logger."
4593
4593
  msgstr ""
4594
4594
 
4595
- # @return [Array<Discorb::Command::Command>]
4595
+ # @return [Array<Discorb::ApplicationCommand::Command>]
4596
4596
  #: ../lib/discorb/client.rb:45
4597
4597
  msgid "The commands that the client is using."
4598
4598
  msgstr ""
@@ -5262,17 +5262,17 @@ msgstr ""
5262
5262
  msgid "A Discord color name."
5263
5263
  msgstr ""
5264
5264
 
5265
- # Discorb::Command
5265
+ # Discorb::ApplicationCommand
5266
5266
  #: ../lib/discorb/command.rb:5
5267
5267
  msgid "Handles application commands."
5268
5268
  msgstr ""
5269
5269
 
5270
- # Discorb::Command::Handler
5270
+ # Discorb::ApplicationCommand::Handler
5271
5271
  #: ../lib/discorb/command.rb:9
5272
5272
  msgid "Module to handle commands."
5273
5273
  msgstr ""
5274
5274
 
5275
- # Discorb::Command::Handler#slash
5275
+ # Discorb::ApplicationCommand::Handler#slash
5276
5276
  #: ../lib/discorb/command.rb:13
5277
5277
  msgid "Add new top-level command."
5278
5278
  msgstr ""
@@ -5364,14 +5364,14 @@ msgstr ""
5364
5364
  msgid "tag|param|options"
5365
5365
  msgstr ""
5366
5366
 
5367
- # Discorb::Command::Handler#slash_group
5367
+ # Discorb::ApplicationCommand::Handler#slash_group
5368
5368
  #: ../lib/discorb/command.rb:41
5369
5369
  msgid "Add new command with group."
5370
5370
  msgstr ""
5371
5371
 
5372
- # @return [Discorb::Command::Command::GroupCommand]
5373
- # @return [Discorb::Command::Command::SubcommandGroup]
5374
- # @return [Discorb::Command::Command]
5372
+ # @return [Discorb::ApplicationCommand::Command::GroupCommand]
5373
+ # @return [Discorb::ApplicationCommand::Command::SubcommandGroup]
5374
+ # @return [Discorb::ApplicationCommand::Command]
5375
5375
  #: ../lib/discorb/command.rb:51
5376
5376
  #: ../lib/discorb/command.rb:69
5377
5377
  #: ../lib/discorb/command.rb:87
@@ -5385,7 +5385,7 @@ msgstr ""
5385
5385
  msgid "tag|see|file:docs/slash_command.md"
5386
5386
  msgstr ""
5387
5387
 
5388
- # Discorb::Command::Handler#message_command
5388
+ # Discorb::ApplicationCommand::Handler#message_command
5389
5389
  #: ../lib/discorb/command.rb:58
5390
5390
  msgid "Add message context menu command."
5391
5391
  msgstr ""
@@ -5397,13 +5397,13 @@ msgstr ""
5397
5397
  msgid "Block to execute."
5398
5398
  msgstr ""
5399
5399
 
5400
- # @yieldparam [Discorb::CommandInteraction::UserMenuCommand]
5400
+ # @yieldparam [Discorb::ApplicationCommandInteraction::UserMenuCommand]
5401
5401
  #: ../lib/discorb/command.rb:69
5402
5402
  #: ../lib/discorb/command.rb:87
5403
5403
  msgid "tag|yieldparam|Interaction"
5404
5404
  msgstr ""
5405
5405
 
5406
- # @yieldparam [Discorb::CommandInteraction::UserMenuCommand] Interaction
5406
+ # @yieldparam [Discorb::ApplicationCommandInteraction::UserMenuCommand] Interaction
5407
5407
  #: ../lib/discorb/command.rb:69
5408
5408
  #: ../lib/discorb/command.rb:87
5409
5409
  msgid "object."
@@ -5421,7 +5421,7 @@ msgstr ""
5421
5421
  msgid "Message object."
5422
5422
  msgstr ""
5423
5423
 
5424
- # Discorb::Command::Handler#user_command
5424
+ # Discorb::ApplicationCommand::Handler#user_command
5425
5425
  #: ../lib/discorb/command.rb:76
5426
5426
  msgid "Add user context menu command."
5427
5427
  msgstr ""
@@ -5431,7 +5431,7 @@ msgstr ""
5431
5431
  msgid "User object."
5432
5432
  msgstr ""
5433
5433
 
5434
- # Discorb::Command::Handler#setup_commands
5434
+ # Discorb::ApplicationCommand::Handler#setup_commands
5435
5435
  #: ../lib/discorb/command.rb:94
5436
5436
  msgid "Setup commands."
5437
5437
  msgstr ""
@@ -5456,7 +5456,7 @@ msgstr ""
5456
5456
  msgid "tag|see|Client#initialize"
5457
5457
  msgstr ""
5458
5458
 
5459
- # Discorb::Command::Command
5459
+ # Discorb::ApplicationCommand::Command
5460
5460
  #: ../lib/discorb/command.rb:119
5461
5461
  msgid "Represents a application command."
5462
5462
  msgstr ""
@@ -5497,7 +5497,7 @@ msgstr ""
5497
5497
  msgid "a new instance of Command"
5498
5498
  msgstr ""
5499
5499
 
5500
- # Discorb::Command::Command::SlashCommand
5500
+ # Discorb::ApplicationCommand::Command::SlashCommand
5501
5501
  #: ../lib/discorb/command.rb:163
5502
5502
  msgid "Represents the slash command."
5503
5503
  msgstr ""
@@ -5518,18 +5518,18 @@ msgstr ""
5518
5518
  msgid "a new instance of SlashCommand"
5519
5519
  msgstr ""
5520
5520
 
5521
- # Discorb::Command::Command::SlashCommand#to_s
5521
+ # Discorb::ApplicationCommand::Command::SlashCommand#to_s
5522
5522
  #: ../lib/discorb/command.rb:185
5523
5523
  msgid "Returns the commands name."
5524
5524
  msgstr ""
5525
5525
 
5526
- # Discorb::Command::Command::GroupCommand
5526
+ # Discorb::ApplicationCommand::Command::GroupCommand
5527
5527
  #: ../lib/discorb/command.rb:236
5528
5528
  msgid "Represents the command with subcommands."
5529
5529
  msgstr ""
5530
5530
 
5531
- # @return [Array<Discorb::Command::Command::SlashCommand, Discorb::Command::Command::SubcommandGroup>]
5532
- # @return [Array<Discorb::Command::Command::SlashCommand>]
5531
+ # @return [Array<Discorb::ApplicationCommand::Command::SlashCommand, Discorb::ApplicationCommand::Command::SubcommandGroup>]
5532
+ # @return [Array<Discorb::ApplicationCommand::Command::SlashCommand>]
5533
5533
  #: ../lib/discorb/command.rb:240
5534
5534
  #: ../lib/discorb/command.rb:361
5535
5535
  msgid "The subcommands of the command."
@@ -5540,20 +5540,20 @@ msgstr ""
5540
5540
  msgid "a new instance of GroupCommand"
5541
5541
  msgstr ""
5542
5542
 
5543
- # Discorb::Command::Command::GroupCommand#slash
5544
- # Discorb::Command::Command::SubcommandGroup#slash
5543
+ # Discorb::ApplicationCommand::Command::GroupCommand#slash
5544
+ # Discorb::ApplicationCommand::Command::SubcommandGroup#slash
5545
5545
  #: ../lib/discorb/command.rb:253
5546
5546
  #: ../lib/discorb/command.rb:376
5547
5547
  msgid "Add new subcommand."
5548
5548
  msgstr ""
5549
5549
 
5550
- # @return [Discorb::Command::Command::SlashCommand]
5550
+ # @return [Discorb::ApplicationCommand::Command::SlashCommand]
5551
5551
  #: ../lib/discorb/command.rb:258
5552
5552
  #: ../lib/discorb/command.rb:380
5553
5553
  msgid "The added subcommand."
5554
5554
  msgstr ""
5555
5555
 
5556
- # Discorb::Command::Command::GroupCommand#group
5556
+ # Discorb::ApplicationCommand::Command::GroupCommand#group
5557
5557
  #: ../lib/discorb/command.rb:301
5558
5558
  msgid "Add new subcommand group."
5559
5559
  msgstr ""
@@ -5568,7 +5568,7 @@ msgstr ""
5568
5568
  msgid "Group description."
5569
5569
  msgstr ""
5570
5570
 
5571
- # Discorb::Command::Command::GroupCommand#to_s
5571
+ # Discorb::ApplicationCommand::Command::GroupCommand#to_s
5572
5572
  #: ../lib/discorb/command.rb:317
5573
5573
  msgid "Returns the command name."
5574
5574
  msgstr ""
@@ -5578,7 +5578,7 @@ msgstr ""
5578
5578
  msgid "The command name."
5579
5579
  msgstr ""
5580
5580
 
5581
- # Discorb::Command::Command::SubcommandGroup
5581
+ # Discorb::ApplicationCommand::Command::SubcommandGroup
5582
5582
  #: ../lib/discorb/command.rb:357
5583
5583
  msgid "Represents the subcommand group."
5584
5584
  msgstr ""
@@ -5589,7 +5589,7 @@ msgid "a new instance of SubcommandGroup"
5589
5589
  msgstr ""
5590
5590
 
5591
5591
  # Discorb::Activity.types
5592
- # Discorb::Command::Command.types
5592
+ # Discorb::ApplicationCommand::Command.types
5593
5593
  #: ../lib/discorb/command.rb:390
5594
5594
  #: ../lib/discorb/gateway_requests.rb:45
5595
5595
  msgid "Returns the value of attribute types."
@@ -9873,7 +9873,7 @@ msgstr ""
9873
9873
  msgid "Response with `UPDATE_MESSAGE`(`7`)."
9874
9874
  msgstr ""
9875
9875
 
9876
- # Discorb::CommandInteraction
9876
+ # Discorb::ApplicationCommandInteraction
9877
9877
  #: ../lib/discorb/interaction.rb:245
9878
9878
  msgid "Represents a command interaction."
9879
9879
  msgstr ""
@@ -9883,12 +9883,12 @@ msgstr ""
9883
9883
  msgid "Implement this."
9884
9884
  msgstr ""
9885
9885
 
9886
- # Discorb::CommandInteraction::SlashCommand
9886
+ # Discorb::ApplicationCommandInteraction::SlashCommand
9887
9887
  #: ../lib/discorb/interaction.rb:254
9888
9888
  msgid "Represents a slash command interaction."
9889
9889
  msgstr ""
9890
9890
 
9891
- # Discorb::CommandInteraction::UserMenuCommand
9891
+ # Discorb::ApplicationCommandInteraction::UserMenuCommand
9892
9892
  #: ../lib/discorb/interaction.rb:310
9893
9893
  msgid "Represents a user context menu interaction."
9894
9894
  msgstr ""
@@ -9898,7 +9898,7 @@ msgstr ""
9898
9898
  msgid "The target user."
9899
9899
  msgstr ""
9900
9900
 
9901
- # Discorb::CommandInteraction::MessageMenuCommand
9901
+ # Discorb::ApplicationCommandInteraction::MessageMenuCommand
9902
9902
  #: ../lib/discorb/interaction.rb:325
9903
9903
  msgid "Represents a message context menu interaction."
9904
9904
  msgstr ""
@@ -9908,7 +9908,7 @@ msgstr ""
9908
9908
  msgid "The target message."
9909
9909
  msgstr ""
9910
9910
 
9911
- # Discorb::CommandInteraction.command_type
9911
+ # Discorb::ApplicationCommandInteraction.command_type
9912
9912
  #: ../lib/discorb/interaction.rb:348
9913
9913
  msgid "Returns the value of attribute command_type."
9914
9914
  msgstr ""