middleman_mynewsdesk 0.0.4 → 0.0.5

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
  SHA1:
3
- metadata.gz: a2d2100418fa31d963e28a3abf60eece649d03e3
4
- data.tar.gz: 38bdb7d0cfc6517a1925a61920944535ccb04c7e
3
+ metadata.gz: 6f0a588b7de22970c7d82e379df1ea0ddb478dc9
4
+ data.tar.gz: 755c8dfc62f92b42f63c8362515add16f36d5843
5
5
  SHA512:
6
- metadata.gz: f4e4a6282865d291a7bfdf31ace00cc0b66c8cc3ffcabfcbf898e731258d93a4bc0c23d308a31fbcac7da5ec1cfd81064967bbcac7646c33c6acb14d8e2c3811
7
- data.tar.gz: 0afe13d160b6257eec36f0422bb220d77d87daa22702fbdf9a3df80b6cd9b5f2a1daff6a94c36ed06aecc37fed49c82b37f5e174d38b73c25e29143ba47c4683
6
+ metadata.gz: 3c081145f9c7708459a5df8047371b33ea8efe258df7704d21bb386659270246281f7e570507a70b3fd955059dc88101885848f4f55ac0a81b85621c3143d3ef
7
+ data.tar.gz: 3679c1db34f1da70362cc9fcd8b37d5d3296aa7464987d6cc2972922b1b829fe2333f25c57836ce2bb61d104a3d5149abd222e84dd2555bf8d0642992801c287
@@ -17,11 +17,11 @@ class Mynewsdesk < ::Middleman::Extension
17
17
  require "http"
18
18
  require "json"
19
19
 
20
- @base_url = "https://www.mynewsdesk.com/services/pressroom/list/#{options.api_key}?format=json"
20
+ @base_url = "https://www.mynewsdesk.com/services/pressroom/list/#{options.api_key}?format=json&limit=100"
21
21
  end
22
22
 
23
- def mynewsdesk_items
23
+ def mynewsdesk_items(limit=20)
24
24
  @items ||= JSON.parse(HTTP.get(@base_url).to_s, object_class: RecursiveOpenStruct).items.item
25
- @items
25
+ @items[0..limit-1]
26
26
  end
27
27
  end
@@ -3,7 +3,7 @@ $:.push File.expand_path('lib', __dir__)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "middleman_mynewsdesk"
6
- s.version = "0.0.4"
6
+ s.version = "0.0.5"
7
7
  s.platform = Gem::Platform::RUBY
8
8
  s.authors = ["Johan Halse"]
9
9
  s.email = ["johan.halse@varvet.com"]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: middleman_mynewsdesk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Johan Halse
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-08-16 00:00:00.000000000 Z
11
+ date: 2018-08-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: middleman-core