gds-api-adapters 67.2.0 → 67.2.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b9e99044909467134a19c5e0f273908fd94afbe72a40f50a5d81dfd4bf467d28
4
- data.tar.gz: 0535e351b0d6899aa363f61bcd8c0ab9b3137389b4279bf9ff195250773c087d
3
+ metadata.gz: 4f4e9476c570389a75e06b65715133d92402d748e4b15fd0b30782a7eca32847
4
+ data.tar.gz: e1e5d3284178b1f22f29dc63d1cf0fde389c82224f56146d6db40304fa211ca0
5
5
  SHA512:
6
- metadata.gz: 796c442ffe778c4377f476db1fdae0d52592c776687aa4d52bc4e3e7f3f3a33fe7cd9e48e40af52e532943fe5b0549cf335ae516d7d4dd149e767f26b7142b7c
7
- data.tar.gz: 3b37865fca30c9e7ff47bd9e8f64fe4579065b48a325eb59cad29a4722170873049c16373f4708c9601e015269875de3ec88612d2a84d64943337e6494aea9fa
6
+ metadata.gz: 392d0964f21b56895aab0fb54a0a566b4c7186f69dbbefa85a31001a255d6cd3a296e982c72df36cc538f93c7beda156430945b86c626a66a50aa35cef29f7b3
7
+ data.tar.gz: 9a41486139d341afcd11559b40407c6bf58836e4aad2f15dce2380297da40e9edb2ef29176410708d067ed692672c54de5cee1b4e455176d4b455682398f30eb
@@ -12,6 +12,9 @@ module GdsApi
12
12
  def publish(options)
13
13
  logger.info("Publishing #{options.fetch(:type)} route #{options.fetch(:base_path)}, routing to #{options.fetch(:rendering_app)}")
14
14
 
15
+ update_type = options.fetch(:update_type, "major")
16
+ locale = options.fetch(:locale, "en")
17
+
15
18
  put_content_response = publishing_api.put_content(
16
19
  options.fetch(:content_id),
17
20
  base_path: options.fetch(:base_path),
@@ -19,7 +22,7 @@ module GdsApi
19
22
  schema_name: options.fetch(:schema_name, "special_route"),
20
23
  title: options.fetch(:title),
21
24
  description: options.fetch(:description, ""),
22
- locale: options.fetch(:locale, "en"),
25
+ locale: locale,
23
26
  details: {},
24
27
  routes: [
25
28
  {
@@ -30,11 +33,11 @@ module GdsApi
30
33
  publishing_app: options.fetch(:publishing_app),
31
34
  rendering_app: options.fetch(:rendering_app),
32
35
  public_updated_at: time.now.iso8601,
33
- update_type: options.fetch(:update_type, "major"),
36
+ update_type: update_type,
34
37
  )
35
38
 
36
39
  publishing_api.patch_links(options.fetch(:content_id), links: options[:links]) if options[:links]
37
- publishing_api.publish(options.fetch(:content_id))
40
+ publishing_api.publish(options.fetch(:content_id), update_type, locale: locale)
38
41
  put_content_response
39
42
  end
40
43
 
@@ -1,3 +1,3 @@
1
1
  module GdsApi
2
- VERSION = "67.2.0".freeze
2
+ VERSION = "67.2.1".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gds-api-adapters
3
3
  version: !ruby/object:Gem::Version
4
- version: 67.2.0
4
+ version: 67.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - GOV.UK Dev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-12-09 00:00:00.000000000 Z
11
+ date: 2020-12-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable