Skip to content

Commit

Permalink
Merge pull request #574 from sinisterstuf/if-channel
Browse files Browse the repository at this point in the history
Use Coffeescript conditional assignment shorthand
  • Loading branch information
seratch authored Apr 10, 2020
2 parents bd319b7 + 16986a6 commit c003c3b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/bot.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ class SlackBot extends Adapter

# Hubot expects all user objects to have a room property that is used in the envelope for the message after it
# is received
user.room = if channel? then channel else ""
user.room = channel ? ""

switch event.subtype
when "bot_message"
Expand Down

0 comments on commit c003c3b

Please sign in to comment.