diff --git a/lib/new_relic/recipes/capistrano3.rb b/lib/new_relic/recipes/capistrano3.rb index 4889159df7..106c4ba19a 100644 --- a/lib/new_relic/recipes/capistrano3.rb +++ b/lib/new_relic/recipes/capistrano3.rb @@ -63,9 +63,11 @@ def send_deployment_notification_to_newrelic end def lookup_changelog - debug "Retrieving changelog for New Relic Deployment details" previous_revision = fetch(:previous_revision) current_revision = fetch(:current_revision) + return unless current_revision && previous_revision + + debug "Retrieving changelog for New Relic Deployment details" if scm == :git log_command = "git --no-pager log --no-color --pretty=format:' * %an: %s' " +