qwtf_discord_bot 5.3.0 → 5.3.1

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: ccd211cda52ba5e8319f7c4cc1466abf47112c8d46b13180d8b89a09a1a2ca68
4
- data.tar.gz: df7bd13a55e52d63128fceeaf07f3ea8c9237471480bbb6cb3e967e73c20babf
3
+ metadata.gz: 020c98479af02b628d8218cb1fdc1225d8b8d38f942b3343504189f6f86af623
4
+ data.tar.gz: 9bdcf614b0783cda3b7e5377a0fc51d808fcc3db4272e4f8a2c315099c40f62b
5
5
  SHA512:
6
- metadata.gz: 0b4a3e1df6ff63f47b167c959570d6d994d92fdc52bdf35b36a70734a09afe3b1caa20b2181b366bea83050c25ca1f3d748b1bf52cc93dfc26e5afd7c6d82150
7
- data.tar.gz: 2974c3a18e557b7788fc75af370a781b43a50eafe85c47740b9298276c79fa33f7e260fc196e5e53eef4fca72a62b8ef19d7607397532469c15e4d8f7f6da911
6
+ metadata.gz: 20cdff7ed5d1d17e45b2b79c6b7f68d4a6c8161d086722dd827126f552abded756c0ead3ebd8622452f329eb2840148eff3e503e6cfa111274d09f0eeba2d145
7
+ data.tar.gz: f9badce721eb64aa4812eb1ae139c2f18cc809c6e20803b67f29cc081dd563374bf452b74ab58bfc6c68badde07dacd6dac0bb50ea0a5dd56610fe7c75761760
data/VERSION CHANGED
@@ -1 +1 @@
1
- 5.3.0
1
+ 5.3.1
@@ -34,7 +34,7 @@ services:
34
34
  - redis
35
35
  environment:
36
36
  - REDIS_URL=redis://redis
37
- - RATINGS_API_URL=http://ratings.fortressone.org/api/v1/
37
+ - RATINGS_API_URL
38
38
  volumes:
39
39
  - type: bind
40
40
  source: "/home/ubuntu/.config/qwtf_discord_bot/config.yaml"
@@ -174,11 +174,11 @@ class QwtfDiscordBotPug # :nodoc:
174
174
 
175
175
  return send_msg("Not a valid team", e.channel) unless pug.team(winning_team_no).any?
176
176
 
177
- players = pug.joined_players.inject({}) do |memo, id|
178
- memo.merge({ id => e.display_name_for(id) })
179
- end
180
-
181
177
  team_results = pug.teams.inject({}) do |teams, (name, player_ids)|
178
+ players = player_ids.inject({}) do |memo, id|
179
+ memo.merge({ id => e.display_name_for(id) })
180
+ end
181
+
182
182
  result = winning_team_no.to_i == name.to_i ? 1 : -1
183
183
  teams.merge({ name => { players: players, result: result } })
184
184
  end
@@ -210,11 +210,11 @@ class QwtfDiscordBotPug # :nodoc:
210
210
  setup_pug(event) do |e, pug|
211
211
  return send_msg(no_active_pug_message, e.channel) unless pug.active?
212
212
 
213
- players = pug.joined_players.inject({}) do |memo, id|
214
- memo.merge({ id => e.display_name_for(id) })
215
- end
216
-
217
213
  team_results = pug.teams.inject({}) do |teams, (name, player_ids)|
214
+ players = player_ids.inject({}) do |memo, id|
215
+ memo.merge({ id => e.display_name_for(id) })
216
+ end
217
+
218
218
  teams.merge({ name => { players: players, result: 0 } })
219
219
  end
220
220
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: qwtf_discord_bot
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.3.0
4
+ version: 5.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sheldon Johnson
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-10-02 00:00:00.000000000 Z
11
+ date: 2020-10-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: discordrb