tumblr-rb 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
data/lib/tumblr.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  require 'weary'
2
2
 
3
3
  class Tumblr
4
- VERSION = "1.1.0"
4
+ VERSION = "1.1.1"
5
5
  GENERATOR = "The Tumblr Gem v#{VERSION}"
6
6
  USER_AGENT = "TumblrGem/#{VERSION} (+http://github.com/mwunsch/tumblr)"
7
7
 
data/lib/tumblr/reader.rb CHANGED
@@ -44,10 +44,12 @@ class Tumblr
44
44
  # Pass an additional type parameter to only get Posts of a certain type.
45
45
  def self.get_posts(response, type = nil)
46
46
  tumblr_post = response['tumblr']['posts']['post']
47
- posts = tumblr_post.respond_to?(:each_pair) ? [tumblr_post] : tumblr_post
48
- posts.collect! { |post| build_post(post) }
49
- return posts.select {|post| post.is_a?(Tumblr.map(type)) } if type
50
- posts
47
+ if tumblr_post
48
+ posts = tumblr_post.respond_to?(:each_pair) ? [tumblr_post] : tumblr_post
49
+ posts.collect! { |post| build_post(post) }
50
+ return posts.select {|post| post.is_a?(Tumblr.map(type)) } if type
51
+ posts
52
+ end
51
53
  end
52
54
 
53
55
  # Build a Post object from Reader's Post XML
data/tumblr-rb.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{tumblr-rb}
8
- s.version = "1.1.0"
8
+ s.version = "1.1.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Mark Wunsch"]
12
- s.date = %q{2010-03-14}
12
+ s.date = %q{2010-03-18}
13
13
  s.default_executable = %q{tumblr}
14
14
  s.description = %q{Ruby library and command line utility to work with the Tumblr Blogging Platform, powered by Weary.}
15
15
  s.email = %q{mark@markwunsch.com}
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 1
7
7
  - 1
8
- - 0
9
- version: 1.1.0
8
+ - 1
9
+ version: 1.1.1
10
10
  platform: ruby
11
11
  authors:
12
12
  - Mark Wunsch
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-03-14 00:00:00 -05:00
17
+ date: 2010-03-18 00:00:00 -04:00
18
18
  default_executable: tumblr
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency