liangzan-contacts 1.2.17 → 1.2.18

Sign up to get free protection for your applications and to get access to all the features.
data/lib/contacts/base.rb CHANGED
@@ -228,7 +228,7 @@ class Contacts
228
228
  email_domain = get_email_domain(email)
229
229
 
230
230
  types.values.find do |klass|
231
- klass::DETECTED_DOMAINS.any? { |m| email_domain.match(m) }
231
+ klass::DETECTED_DOMAINS.any? { |m| email_domain.to_s.match(m) }
232
232
  end
233
233
  end
234
234
 
@@ -3,7 +3,7 @@ class Contacts
3
3
  DETECTED_DOMAINS = [ /one\.lt/i ]
4
4
  LOGIN_URL = "http://w33.one.lt/logonSubsite.do?subsite=pastas"
5
5
  EMAIL_URL = "http://email.one.lt/"
6
- ADDRESS_BOOK_URL = "http://email.one.lt/index.html?screen=RedirectServer&pane=contacts"
6
+ ADDRESS_BOOK_URL = "http://w33.one.lt/resinRedir.do?pane=email"
7
7
  PROTOCOL_ERROR = "One.lt has changed its protocols, please upgrade this library first. If that does not work, report this error at http://rubyforge.org/forum/?group_id=2693"
8
8
 
9
9
  attr_accessor :cookies
@@ -25,18 +25,6 @@ class Contacts
25
25
  elsif forward.nil? || !forward.match('tkn')
26
26
  raise ConnectionError, PROTOCOL_ERROR
27
27
  end
28
-
29
- forward+= '&subsite=pastas' unless forward.match('subsite=pastas')
30
- #p forward
31
-
32
- # http://w32.one.lt/logonSubsite.do?subsite=pastas&tkn=3229
33
- data, resp, self.cookies, forward, old_url = get(forward, self.cookies, LOGIN_URL) + [forward]
34
-
35
- # http://pastas.one.lt/?tkn=979
36
- data, resp, self.cookies, forward, old_url = get(forward, self.cookies, old_url) + [forward]
37
-
38
- # http://email.one.lt/?action=LoginUser
39
- data, resp, self.cookies, forward, old_url = get(forward, self.cookies, old_url) + [forward]
40
28
  end
41
29
 
42
30
  def contacts
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: liangzan-contacts
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.17
4
+ version: 1.2.18
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -13,11 +13,11 @@ authors:
13
13
  autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
- date: 2012-03-26 00:00:00.000000000Z
16
+ date: 2012-03-27 00:00:00.000000000Z
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency
19
19
  name: json
20
- requirement: &10538000 !ruby/object:Gem::Requirement
20
+ requirement: &8571580 !ruby/object:Gem::Requirement
21
21
  none: false
22
22
  requirements:
23
23
  - - ~>
@@ -25,10 +25,10 @@ dependencies:
25
25
  version: 1.6.5
26
26
  type: :runtime
27
27
  prerelease: false
28
- version_requirements: *10538000
28
+ version_requirements: *8571580
29
29
  - !ruby/object:Gem::Dependency
30
30
  name: gdata_19
31
- requirement: &10536780 !ruby/object:Gem::Requirement
31
+ requirement: &8570060 !ruby/object:Gem::Requirement
32
32
  none: false
33
33
  requirements:
34
34
  - - ~>
@@ -36,10 +36,10 @@ dependencies:
36
36
  version: 1.1.3
37
37
  type: :runtime
38
38
  prerelease: false
39
- version_requirements: *10536780
39
+ version_requirements: *8570060
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: nokogiri
42
- requirement: &10535740 !ruby/object:Gem::Requirement
42
+ requirement: &8569140 !ruby/object:Gem::Requirement
43
43
  none: false
44
44
  requirements:
45
45
  - - ~>
@@ -47,7 +47,7 @@ dependencies:
47
47
  version: 1.5.0
48
48
  type: :runtime
49
49
  prerelease: false
50
- version_requirements: *10535740
50
+ version_requirements: *8569140
51
51
  description: A universal interface to grab contact list information from Yahoo, AOL,
52
52
  Gmail, Hotmail, Plaxo, GMX.net, Web.de, inbox.lt, seznam.cz, t-online.de. Now supporting
53
53
  Ruby 1.9.