ruby-hackernews 1.3.2 → 1.3.3

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -8,7 +8,7 @@ require 'rake/testtask'
8
8
 
9
9
  spec = Gem::Specification.new do |s|
10
10
  s.name = 'ruby-hackernews'
11
- s.version = '1.3.2'
11
+ s.version = '1.3.3'
12
12
  s.add_dependency('require_all', '>= 1.1.0')
13
13
  s.add_dependency('mechanize', '>= 1.0.0')
14
14
  s.has_rdoc = false
@@ -14,7 +14,7 @@ module RubyHackernews
14
14
  @user = user
15
15
  @time = time
16
16
  @comments_info = comments
17
- @cache = PageFetcher.new(@comments_info.page)
17
+ @cache = PageFetcher.new(@comments_info.page) if @comments_info
18
18
  end
19
19
 
20
20
  def text
@@ -17,6 +17,7 @@ module RubyHackernews
17
17
  def find_by_id(id)
18
18
  page = agent.get(ConfigurationService.base_url + "item?id=#{id}")
19
19
  comment = parse_comment(page.search("table")[2].search("tr").first)
20
+ comment.instance_variable_set(:@absolute_link, "item?id=#{id}")
20
21
  get_comments_entities(page.search("table")[3]).each do |c|
21
22
  comment << c
22
23
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-hackernews
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.2
4
+ version: 1.3.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-12-10 00:00:00.000000000 Z
12
+ date: 2012-12-15 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: require_all
@@ -51,34 +51,34 @@ extra_rdoc_files: []
51
51
  files:
52
52
  - README.rdoc
53
53
  - Rakefile
54
- - lib/ruby-hackernews/domain/comment/comment.rb
55
- - lib/ruby-hackernews/domain/entry/user_info.rb
54
+ - lib/ruby-hackernews.rb
55
+ - lib/ruby-hackernews/domain/entry/comments_info.rb
56
56
  - lib/ruby-hackernews/domain/entry/time_info.rb
57
- - lib/ruby-hackernews/domain/entry/entry.rb
58
- - lib/ruby-hackernews/domain/entry/link_info.rb
59
57
  - lib/ruby-hackernews/domain/entry/voting_info.rb
60
- - lib/ruby-hackernews/domain/entry/comments_info.rb
58
+ - lib/ruby-hackernews/domain/entry/link_info.rb
59
+ - lib/ruby-hackernews/domain/entry/entry.rb
60
+ - lib/ruby-hackernews/domain/entry/user_info.rb
61
61
  - lib/ruby-hackernews/domain/user.rb
62
- - lib/ruby-hackernews/services/comment_service.rb
63
- - lib/ruby-hackernews/services/text_service.rb
64
- - lib/ruby-hackernews/services/user_info_service.rb
62
+ - lib/ruby-hackernews/domain/comment/comment.rb
63
+ - lib/ruby-hackernews/services/configuration_service.rb
64
+ - lib/ruby-hackernews/services/page_fetcher.rb
65
+ - lib/ruby-hackernews/services/login_service.rb
65
66
  - lib/ruby-hackernews/services/mechanize_context.rb
66
- - lib/ruby-hackernews/services/entry_service.rb
67
67
  - lib/ruby-hackernews/services/not_authenticated_error.rb
68
- - lib/ruby-hackernews/services/login_service.rb
69
- - lib/ruby-hackernews/services/page_fetcher.rb
68
+ - lib/ruby-hackernews/services/signup_service.rb
69
+ - lib/ruby-hackernews/services/entry_service.rb
70
+ - lib/ruby-hackernews/services/user_info_service.rb
71
+ - lib/ruby-hackernews/services/comment_service.rb
72
+ - lib/ruby-hackernews/services/voting_service.rb
73
+ - lib/ruby-hackernews/services/text_service.rb
74
+ - lib/ruby-hackernews/services/parsers/text_parser.rb
70
75
  - lib/ruby-hackernews/services/parsers/user_info_parser.rb
71
- - lib/ruby-hackernews/services/parsers/link_info_parser.rb
72
76
  - lib/ruby-hackernews/services/parsers/entry_parser.rb
77
+ - lib/ruby-hackernews/services/parsers/link_info_parser.rb
73
78
  - lib/ruby-hackernews/services/parsers/time_info_parser.rb
74
- - lib/ruby-hackernews/services/parsers/text_parser.rb
75
- - lib/ruby-hackernews/services/parsers/entry_page_parser.rb
76
- - lib/ruby-hackernews/services/parsers/comments_info_parser.rb
77
79
  - lib/ruby-hackernews/services/parsers/voting_info_parser.rb
78
- - lib/ruby-hackernews/services/configuration_service.rb
79
- - lib/ruby-hackernews/services/voting_service.rb
80
- - lib/ruby-hackernews/services/signup_service.rb
81
- - lib/ruby-hackernews.rb
80
+ - lib/ruby-hackernews/services/parsers/comments_info_parser.rb
81
+ - lib/ruby-hackernews/services/parsers/entry_page_parser.rb
82
82
  homepage: http://github.com/bolthar/ruby-hackernews
83
83
  licenses: []
84
84
  post_install_message: