Skip to content

Commit

Permalink
Merge pull request #8905 from koic/remove_redundant_blank_for_to_json…
Browse files Browse the repository at this point in the history
…_message

Remove redundant blank for `Lint/ToJSON`'s offense message
  • Loading branch information
koic committed Oct 18, 2020
2 parents b6f02a3 + 0f621dd commit 679eef1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/rubocop/cop/lint/to_json.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ module Lint
class ToJSON < Base
extend AutoCorrector

MSG = ' `#to_json` requires an optional argument to be parsable ' \
MSG = '`#to_json` requires an optional argument to be parsable ' \
'via JSON.generate(obj).'

def on_def(node)
Expand Down
2 changes: 1 addition & 1 deletion spec/rubocop/cop/lint/to_json_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
it 'registers an offense and corrects using `#to_json` without arguments' do
expect_offense(<<~RUBY)
def to_json
^^^^^^^^^^^ `#to_json` requires an optional argument to be parsable via JSON.generate(obj).
^^^^^^^^^^^ `#to_json` requires an optional argument to be parsable via JSON.generate(obj).
end
RUBY

Expand Down

0 comments on commit 679eef1

Please sign in to comment.