Skip to content

Commit

Permalink
Fix "bundle exec rails mastodon:setup" crashing in some circumstances (
Browse files Browse the repository at this point in the history
…mastodon#16976)

Fix regression from mastodon#16896
  • Loading branch information
ClearlyClaire authored and kadoshita committed Nov 28, 2021
1 parent a7a0eec commit 9f24dde
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/tasks/mastodon.rake
Original file line number Diff line number Diff line change
Expand Up @@ -350,11 +350,11 @@ namespace :mastodon do
end
end.join("\n")

generated_header = "# Generated with mastodon:setup on #{Time.now.utc}\n\n"
generated_header = "# Generated with mastodon:setup on #{Time.now.utc}\n\n".dup

if incompatible_syntax
generated_header << "Some variables in this file will be interpreted differently whether you are\n"
generated_header << "using docker-compose or not.\n\n"
generated_header << "# Some variables in this file will be interpreted differently whether you are\n"
generated_header << "# using docker-compose or not.\n\n"
end

File.write(Rails.root.join('.env.production'), "#{generated_header}#{env_contents}\n")
Expand Down

0 comments on commit 9f24dde

Please sign in to comment.