contentful-scheduler-custom 1.7.1.1 → 1.7.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1596d1d07c6f6672a12b35eabd86666ca730a95ff269c56911907de7ed232de3
4
- data.tar.gz: 95fe96c6fb8603da77e38534cfa4fc84b07cb47b3304f36732bca2fc2704afeb
3
+ metadata.gz: 56e797022c1e739f7cfd54ea88d7e5c25750a031ad7f392a89dd0326f2b6d65a
4
+ data.tar.gz: 20d68bf7fa9399e57193b568fd540551eb08f09cb7963052203ef39cd6ba9713
5
5
  SHA512:
6
- metadata.gz: 625c38430ef0b8fd3067059a0651ddf42ef3ddcf04e88ba92b1342592daa0b30ef14880163a7fea43d38841bbaa8d60e0d2b580dd7bd01f3a21c1cf0c6937b04
7
- data.tar.gz: 7436efd8a96a0af2c2466753d47a28f7335ccf1e2cbb7663acc71038cba38aa21a94c76c2f5fc1c5f0dfa67dbe43a898ef8ffb0cd932225733ad926a265f0d94
6
+ metadata.gz: 17606c06f7e4791b2bb916623758c6511194f109cc6fe5d6a758c4344888db73b1319abd8f0947b54b74713e8c1f5a975ba8ce0542431142a5b8831b57a07f4c
7
+ data.tar.gz: 7380c2b376192ff3ce25b2d3fa318e1e3b01e9bde1a9edf887c61457a2baebff45de549fe07c394ef59d11c35795fbe85b9641aa547118af94d3db0e750f7e2a
@@ -11,7 +11,7 @@ module Contentful
11
11
 
12
12
  def self.perform(space_id, entry_id, token)
13
13
 
14
- logger = Logger.new(STDOUT)
14
+ logger = ::Contentful::Scheduler.config[:logger]
15
15
 
16
16
  client = Contentful::Client.new(
17
17
  space: space_id,
@@ -35,7 +35,7 @@ module Contentful
35
35
  clientManagement.entries.find(space_id, id).publish
36
36
  end
37
37
  end
38
- logger.info("Publishing entry id ===>>> #{entry_id}")
38
+
39
39
  clientManagement.entries.find(space_id, entry_id).publish
40
40
  end
41
41
  end
@@ -11,12 +11,17 @@ module Contentful
11
11
 
12
12
  def self.perform(space_id, entry_id, token)
13
13
 
14
+ =begin
15
+ We wont unpublish linked items as they could have been used somewhere else
16
+ even though we enable these commentted code Contentful handles this situtation
17
+ ethically.
14
18
  logger = Logger.new(STDOUT)
15
19
 
16
20
  client = Contentful::Client.new(
17
21
  space: space_id,
18
22
  access_token: ::Contentful::Scheduler.config[:spaces][space_id][:delivery_token]
19
23
  )
24
+ =end
20
25
 
21
26
  clientManagement = ::Contentful::Management::Client.new(
22
27
  token,
@@ -25,6 +30,7 @@ module Contentful
25
30
  application_version: Contentful::Scheduler::VERSION
26
31
  )
27
32
 
33
+ =begin
28
34
  linked_entries = client.entries(links_to_entry: entry_id)
29
35
 
30
36
  if !linked_entries.raw["includes"].nil? && !linked_entries.raw["includes"]["Entry"].nil?
@@ -35,7 +41,8 @@ module Contentful
35
41
  clientManagement.entries.find(space_id, id).unpublish
36
42
  end
37
43
  end
38
- logger.info("Unpublishing entry id ===>>> #{entry_id}")
44
+ =end
45
+
39
46
  clientManagement.entries.find(space_id, entry_id).unpublish
40
47
  end
41
48
  end
@@ -1,5 +1,5 @@
1
1
  module Contentful
2
2
  module Scheduler
3
- VERSION = "1.7.1.1"
3
+ VERSION = "1.7.1.2"
4
4
  end
5
- end
5
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: contentful-scheduler-custom
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.1.1
4
+ version: 1.7.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Contentful GmbH (David Litvak Bruno0
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-01 00:00:00.000000000 Z
11
+ date: 2019-04-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: contentful