@@ -10,7 +10,7 @@ namespace :publishing_api do
1010 presenter = IndexPresenter . new
1111
1212 unless shell . yes? ( "You are about to publish travel advice index content item. Would you like to proceed? (yes/no)" )
13- shell . say_error ( "Aborted" )
13+ shell . say "Aborted"
1414 next
1515 end
1616 GdsApi . publishing_api . put_content ( presenter . content_id , presenter . render_for_publishing_api )
@@ -24,7 +24,7 @@ namespace :publishing_api do
2424 alternative_path = "/foreign-travel-advice/#{ args [ :new_country_slug ] } "
2525
2626 unless shell . yes? ( "You are about to unpublish a published travel advice page and email signup page for #{ country } and redirect to #{ alternative_path } " )
27- shell . say_error ( "Aborted" )
27+ shell . say "Aborted"
2828 next
2929 end
3030 GdsApi . publishing_api . unpublish ( country . email_signup_content_id , type : "redirect" , alternative_path : "#{ alternative_path } /email-signup" )
@@ -42,7 +42,7 @@ namespace :publishing_api do
4242 desc "republish all published editions to publishing-api"
4343 task republish_editions : :environment do
4444 unless shell . yes? ( "You are about to republish all travel advice content items. Would you like to proceed? (yes/no)" )
45- shell . say_error ( "Aborted" )
45+ shell . say "Aborted"
4646 next
4747 end
4848 TravelAdviceEdition . published . each do |edition |
@@ -86,7 +86,7 @@ namespace :publishing_api do
8686 desc "republish a published edition to publishing-api for a country"
8787 task :republish_edition , [ :country_slug ] => :environment do |_task , args |
8888 unless shell . yes? ( "You are about to republish published travel advice for #{ args [ :country_slug ] } . Would you like to proceed? (yes/no)" )
89- shell . say_error ( "Aborted" )
89+ shell . say "Aborted"
9090 next
9191 end
9292 edition = TravelAdviceEdition . published . find_by ( country_slug : args [ :country_slug ] )
@@ -113,7 +113,7 @@ namespace :publishing_api do
113113 presenter = EmailAlertSignup ::IndexPresenter . new
114114
115115 unless shell . yes? ( "You are about to republish email sign up pages for travel advice index. Would you like to proceed? (yes/no)" )
116- shell . say_error ( "Aborted" )
116+ shell . say "Aborted"
117117 next
118118 end
119119 GdsApi . publishing_api . put_content ( presenter . content_id , presenter . content_payload )
@@ -123,7 +123,7 @@ namespace :publishing_api do
123123 desc "republish email signup content item for all countries"
124124 task editions : :environment do
125125 unless shell . yes? ( "You are about to republish email signup pages for all countries. Would you like to proceed? (yes/no)" )
126- shell . say_error ( "Aborted" )
126+ shell . say "Aborted"
127127 next
128128 end
129129 TravelAdviceEdition . published . each do |edition |
@@ -144,7 +144,7 @@ namespace :publishing_api do
144144 presenter = EmailAlertSignup ::EditionPresenter . new ( edition )
145145
146146 unless shell . yes? ( "You are about to republish email signup for #{ args [ :country_slug ] } . Would you like to proceed? (yes/no)" )
147- shell . say_error ( "Aborted" )
147+ shell . say "Aborted"
148148 next
149149 end
150150 GdsApi . publishing_api . put_content ( presenter . content_id , presenter . content_payload )
0 commit comments