Skip to content

Commit 5c6c8d5

Browse files
committed
Omits extra output when just adding comments
1 parent e90f441 commit 5c6c8d5

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

Gemfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: .
33
specs:
4-
linear-cli (0.6.1)
4+
linear-cli (0.7.0)
55
base64 (~> 0.2)
66
dry-cli (~> 1.0)
77
dry-cli-completion (~> 1.0)

lib/linear/commands/issue.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ module Issue
2222
issue: %w[i issues] # aliases for the main issue command itself
2323
}.freeze
2424

25-
2625
def issue_comment(issue, comment)
2726
issue.add_comment(comment)
2827
prompt.ok("Comment added to #{issue.identifier}")
@@ -45,6 +44,7 @@ def update_issue(issue, **options)
4544
issue_comment(issue, options[:comment]) if options[:comment]
4645
return close_issue(issue, **options) if options[:close]
4746
return issue_pr(issue) if options[:pr]
47+
return if options[:comment]
4848

4949
prompt.warn('No action taken, no options specified')
5050
prompt.ok('Issue was not updated')

lib/linear/commands/issue/update.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ class Update
2626

2727
def call(issue_ids:, **options)
2828
prompt.error('You should provide at least one issue ID') && raise(SmellsBad) if issue_ids.empty?
29+
2930
logger.debug('Updating issues', issue_ids:, options:)
3031
Rubyists::Linear::Issue.find_all(issue_ids).each do |issue|
3132
update_issue(issue, **options)

0 commit comments

Comments
 (0)