discorb 0.5.4 → 0.5.5

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 62a9092a32b87c1edbb193c7b3de777b499257a9b08f92f88a741506ecef58fe
4
- data.tar.gz: 3df9d14c6c7ec041d9887b3479af2417295e17b148c1aea780230e84b5c0d799
3
+ metadata.gz: d6919eceb7431839769fc4bca402df56fef34e50d12f47f6cc8824e210bef95b
4
+ data.tar.gz: 8e50f4f53b5a1b52d3c4e29f9856cac2469a067c7d6005542a520081622d8da2
5
5
  SHA512:
6
- metadata.gz: f26088e7ce6f9a4bd5877263cc716722ca3523047df3623e49a082940251d3a97cea81c289239a3c9f0b456f9a21ee637f1adcd8e804084550b6af10c2aea02b
7
- data.tar.gz: bda9f44c79c089e7cf55eeef4e774c20e3891baf09e0eb73fd2faa6e9337e5abca02b66c0e5e2c2db386d136144441f34afdf306bb427b3fcf40fa8f85f875ae
6
+ metadata.gz: 45a3649f783094e691921a041428df1a7a1d368705a116240385b94e9d2b30983a232b47a5d702c50ae61a7a4b36ef3252f6b7f48992832c6f4073cadab08d26
7
+ data.tar.gz: 1a89fba62ef9b03db524eb6b57e409280c1888709e248df33cd1c42266c12ae534535a39c2765046a56eebd66adb5b8472f202115cf0e16cfcbbefee04e17e1a
data/Changelog.md CHANGED
@@ -127,4 +127,8 @@
127
127
 
128
128
  ## 0.5.4
129
129
 
130
- - Fix: Fix issue of receiving component events
130
+ - Fix: Fix issue of receiving component events
131
+
132
+ ## 0.5.5
133
+
134
+ - Fix: Fix some bugs
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- discorb (0.5.4)
4
+ discorb (0.5.5)
5
5
  async (~> 1.30.1)
6
6
  async-http (~> 0.56.5)
7
7
  async-websocket (~> 0.19.0)
@@ -4,7 +4,7 @@ module Discorb
4
4
  # @return [String] The API base URL.
5
5
  API_BASE_URL = "https://discord.com/api/v9"
6
6
  # @return [String] The version of discorb.
7
- VERSION = "0.5.4"
7
+ VERSION = "0.5.5"
8
8
  # @return [String] The user agent for the bot.
9
9
  USER_AGENT = "DiscordBot (https://github.com/discorb-lib/discorb #{VERSION}) Ruby/#{RUBY_VERSION}"
10
10
 
data/lib/discorb/embed.rb CHANGED
@@ -65,9 +65,9 @@ module Discorb
65
65
  @timestamp = data[:timestamp] && Time.iso8601(data[:timestamp])
66
66
  @type = data[:type]
67
67
  @color = data[:color] && Color.new(data[:color])
68
- @footer = data[:footer] && Footer.new(data[:footer][:text], icon: data[:footer][:icon])
68
+ @footer = data[:footer] && Footer.new(data[:footer][:text], icon: data[:footer][:icon_url])
69
69
  @author = if data[:author]
70
- Author.new(data[:author][:name], icon: data[:author][:icon],
70
+ Author.new(data[:author][:name], icon: data[:author][:icon_url],
71
71
  url: data[:author][:url])
72
72
  end
73
73
  @thumbnail = data[:thumbnail] && Thumbnail.new(data[:thumbnail])
@@ -171,10 +171,10 @@ if (dir = ARGV[0])
171
171
  $path += "/#{dir}"
172
172
  if Dir.exist?($path)
173
173
  if Dir.empty?($path)
174
- gputs "Found \e[30m#{dir}\e[90m and empty, using this directory."
174
+ iputs "Found \e[30m#{dir}\e[90m and empty, using this directory."
175
175
  else
176
176
  if $values[:force]
177
- gputs "Found \e[30m#{dir}\e[90m and not empty, but force is on, using this directory."
177
+ iputs "Found \e[30m#{dir}\e[90m and not empty, but force is on, using this directory."
178
178
  else
179
179
  eputs "Directory \e[31m#{dir}\e[91m already exists and not empty. Use \e[31m-f\e[91m to force."
180
180
  exit
@@ -182,7 +182,7 @@ if (dir = ARGV[0])
182
182
  end
183
183
  else
184
184
  Dir.mkdir($path)
185
- gputs "Couldn't find \e[30m#{dir}\e[90m, created directory."
185
+ iputs "Couldn't find \e[30m#{dir}\e[90m, created directory."
186
186
  end
187
187
  Dir.chdir($path)
188
188
  end
@@ -336,7 +336,7 @@ module Discorb
336
336
  private
337
337
 
338
338
  def _set_data(data)
339
- @target = Message.new(@client, data[:resolved][:messages][data[:target_id].to_sym].merge({ guild_id: @guild_id.to_s }))
339
+ @target = Message.new(@client, data[:resolved][:messages][data[:target_id].to_sym])
340
340
  @client.commands.find { |c| c.name == data[:name] && c.type_raw == 3 }.block.call(self, @target)
341
341
  end
342
342
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: discorb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.4
4
+ version: 0.5.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - sevenc-nanashi
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-09-11 00:00:00.000000000 Z
11
+ date: 2021-09-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: async