discorb 0.11.2 → 0.11.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f0bee36d996a7e3108f2d02247a0d7516ade1811aeb5a354d1d41f509373381d
4
- data.tar.gz: ce6c4f496b8ed5309cd3798b8cf25e271e77e75617631010d77f5ab3347a26aa
3
+ metadata.gz: 60cb51026c0c1eb4e339a808b7510dd6ff7ee01a3a14b556f9b563eb35c5a14c
4
+ data.tar.gz: ab9d5a60d0c798af8dc61b3d43bbdd29f289cd1d0b709080ffeb89e0c37319b0
5
5
  SHA512:
6
- metadata.gz: 514f4b1ce307abe3424fa666a9fab56282e7b3817371411661675507658a42a92c23cda56e6358765fcad25bae69b850e754882576392ddc45da8be08ff3d252
7
- data.tar.gz: e11b02e78f5029a0e544a0c7a55d79ee42ee22276160ba0f00dad0bd85c2d5d15109fa28c50dbfccbaf61066e293175e6b38357db396aeaba4b3033e38dbf2c4
6
+ metadata.gz: dafecc3709155ce8c2d445b7ca19c5aa68744db6235f21dddea897dbc6d9c0dea83a226e49b6ef0a86649557abe7cb85463b43235cd721c5209d52c1cef31e07
7
+ data.tar.gz: 1f14f8800518ac494b2776d595585723a7e9a715be3c8f48b6ebc9a3857ae175951b82b1e1954765e2949df8839d9f995c1516f0db71825367806f06ecdb7707
data/Changelog.md CHANGED
@@ -4,6 +4,11 @@
4
4
 
5
5
  ## v0.11
6
6
 
7
+ ### v0.11.3
8
+
9
+ - Add: Add `Snowflake#id` as alias for `Snowflake#to_s`
10
+ - Fix: Fix `Message#unpin`
11
+
7
12
  ### v0.11.2
8
13
 
9
14
  - Add: Add `setup` event
@@ -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.11.2"
7
+ VERSION = "0.11.3"
8
8
  # @return [String] The user agent for the bot.
9
9
  USER_AGENT = "DiscordBot (https://discorb-lib.github.io #{VERSION}) Ruby/#{RUBY_VERSION}"
10
10
 
@@ -64,6 +64,10 @@ module Discorb
64
64
  # Increment of snowflake.
65
65
  #
66
66
  # @return [Integer] Increment of snowflake.
67
+ # @!attribute [r] id
68
+ # Alias of to_s.
69
+ #
70
+ # @return [String] The snowflake.
67
71
 
68
72
  #
69
73
  # Compares snowflake with other object.
@@ -105,5 +109,7 @@ module Discorb
105
109
  def increment
106
110
  @value & 0xFFF
107
111
  end
112
+
113
+ alias id to_s
108
114
  end
109
115
  end
@@ -455,7 +455,9 @@ module Discorb
455
455
  # @macro async
456
456
  # @macro http
457
457
  #
458
- def unpin
458
+ # @param [String] reason The reason for unpinning the message.
459
+ #
460
+ def unpin(reason: nil)
459
461
  Async do
460
462
  channel.unpin_message(self, reason: reason).wait
461
463
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: discorb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.2
4
+ version: 0.11.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - sevenc-nanashi