Skip to content

Commit

Permalink
Remove useless guard statement
Browse files Browse the repository at this point in the history
`#placeholder_text` already has a guard clause. Also removes warnings
about `@placeholder` being uninitialised.
  • Loading branch information
CGA1123 committed Nov 22, 2024
1 parent 404de4c commit 41dc84d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/slack/block_kit/element/timepicker.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class Timepicker
TYPE = 'timepicker'

def initialize(action_id:, placeholder: nil, initial: nil, emoji: nil, focus_on_load: nil)
@placeholder = placeholder_text(placeholder, emoji) if placeholder
@placeholder = placeholder_text(placeholder, emoji)
@initial_time = initial
@action_id = action_id
@focus_on_load = focus_on_load
Expand Down

0 comments on commit 41dc84d

Please sign in to comment.