Skip to content

Commit 3b895b8

Browse files
committed
Make !video command to show the dups count
1 parent 8a9cd17 commit 3b895b8

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/Bot/Friday.hs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,11 +213,13 @@ videoCommand =
213213
liftR (const currentVideo) $
214214
replyOnNothing "No videos in the queue" $
215215
cmapR entityPayload $
216+
liftFst (fmap length . fridayVideosByYtId . fridayVideoName) $
216217
cmapR
217-
(\video ->
218+
(\(video, times) ->
218219
[qms|{fridayVideoDate video}
219220
<{fridayVideoAuthor video}>
220-
{fridayVideoName video}|]) $
221+
{fridayVideoName video} —
222+
This video was suggested {times} times.|]) $
221223
Reaction replyMessage
222224

223225
currentFridayState :: Effect (Entity FridayState)

0 commit comments

Comments
 (0)