lita-discord_oauth 0.1.2.alpha.55 → 0.1.2.alpha.58

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
  SHA1:
3
- metadata.gz: ffaf738fc02137ca148ea7d4a993d5f9afa0b4ab
4
- data.tar.gz: 6d122ce5154761e3372a5ed24a4c6775acab7532
3
+ metadata.gz: 63660dd6e427deb93ec2e42e6b9880d45e4d719d
4
+ data.tar.gz: 6f21635f23bc13f14c6d0fe42d908bf89ed29116
5
5
  SHA512:
6
- metadata.gz: 2fad54410faea5c509b1f87722d4e0c8f9edbcbf79d6acbb4cbc6c5bc47f220d904ac89095b064cb0e70ab38398604e20e8edb8226aa9d1454b1f3fb046816be
7
- data.tar.gz: 8289c890a7905d6f15b9b25942a96d52214da2324872573f08451b7661cb1e93ab58cc3c833ca82f48549d1c381aebfad4858dcb3a8a6f020b00f0b647c764b8
6
+ metadata.gz: 29e7822b19a76132d089686e73250b43d3ad2811d997ca589983ad33b4e7a869b75b176921973086a1545973cbb14b565ae6a43dbbbd88e3dba6eee6a02854f6
7
+ data.tar.gz: b10fc049fd6d4ba16cbed69d4bb76cacebb3021669e0e197e085df3b3693bc7622d1c742e4436570dec02263a53bf41036524308c7c9bc18194394c16b34f936
@@ -1,8 +1,12 @@
1
+ require 'lita/handler/chat_router'
2
+
1
3
  module Lita
2
4
  # A namespace to hold all subclasses of {Handler}.
3
5
  module Handlers
4
6
  # Provides online help about Lita commands for users.
5
- class DiscordHelp < Handler
7
+ class DiscordHelp
8
+ extend Lita::Handler::ChatRouter
9
+
6
10
  route(/^help\s*(.+)?/, :help, command: true, help: {
7
11
  "help" => t("help.help_value"),
8
12
  t("help.help_command_key") => t("help.help_command_value")
@@ -35,7 +39,7 @@ module Lita
35
39
  value_words.each do |word|
36
40
  new_value_line = "#{value_line} #{word}"
37
41
 
38
- if new_value_line.length > value_width
42
+ if new_value_line.length > value_width + key_width + 1
39
43
  value_text += "#{value_line}\n" + ''.ljust(key_width + 1, ' ')
40
44
  value_line = word
41
45
  else
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lita-discord_oauth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2.alpha.55
4
+ version: 0.1.2.alpha.58
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cas Eliëns