Skip to content

Commit

Permalink
588: deleting old credit_line and adding new one with '\n'
Browse files Browse the repository at this point in the history
  • Loading branch information
qwerty2323 committed Mar 3, 2018
1 parent ae74616 commit f31347e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/github_changelog_generator/generator/generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ def compound_changelog

log += File.read(options[:base]) if File.file?(options[:base])

credit_line = "\n\n\\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)* \n"
log.gsub!(credit_line, "") # Remove old credit lines
log += credit_line
credit_line = "\n\n\\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*"
log.gsub!(/#{credit_line}(\n)?/, "") # Remove old credit lines
log += "#{credit_line}\n"

@log = log
end
Expand Down

0 comments on commit f31347e

Please sign in to comment.