Skip to content

Commit

Permalink
Merge pull request #3666 from alphagov/unpublish-help-json
Browse files Browse the repository at this point in the history
Unpublish help json
  • Loading branch information
BeckaL authored Jun 27, 2023
2 parents cded8bd + c4bec8f commit be7b41d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 0 additions & 6 deletions lib/special_route_publisher.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,6 @@ def self.routes
title: "Cookies on GOV.UK",
description: "You can choose which cookies you're happy for GOV.UK to use.",
},
{
content_id: "50aa0d27-ea4a-49b7-a1e6-98abd1115f60",
base_path: "/help.json",
title: "Help using GOV.UK",
description: "Find out about GOV.UK, including the use of cookies, accessibility of the site, the privacy notice and terms and conditions of use rendered in JSON format here.",
},
{
content_id: "3c991cea-cdee-4e58-b8d1-d38e7c0e6327",
base_path: "/random",
Expand Down
6 changes: 6 additions & 0 deletions lib/tasks/publishing_api.rake
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,10 @@ namespace :publishing_api do
I18n.locale = :cy
CalendarPublisher.new(Calendar.find("bank-holidays"), slug: "gwyliau-banc").publish
end

desc "Unpublish help.json"
task unpublish_help_json: :environment do
api_client = GdsApi::PublishingApi.new(Plek.find("publishing-api"), bearer_token: ENV["PUBLISHING_API_BEARER_TOKEN"])
api_client.unpublish("50aa0d27-ea4a-49b7-a1e6-98abd1115f60", type: "redirect", alternative_path: "/help", discard_drafts: true)
end
end

0 comments on commit be7b41d

Please sign in to comment.