biller_bot_resource 0.0.4 → 0.0.5

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.
@@ -1,8 +1,19 @@
1
1
  class BillerBotResource::Configuration
2
- attr_accessor :site, :logger, :api_key, :timeout
3
-
2
+ attr_accessor :site, :logger, :timeout
3
+
4
4
  def initialize
5
5
  self.site = "https://billerbot.com"
6
- self.timeout = 10 # seconds. Low value so we fail fast
6
+ self.timeout = 7 # seconds. Low value so we fail fast
7
+ end
8
+
9
+ ##
10
+ # We store the API key within the context of the thread because this is more
11
+ # likely to change between requests.
12
+ def api_key=(key)
13
+ Thread.current["active.resource.currentthread.api_key"] = key
14
+ end
15
+
16
+ def api_key
17
+ Thread.current["active.resource.currentthread.api_key"]
7
18
  end
8
19
  end
@@ -1,3 +1,3 @@
1
1
  module BillerBotResource
2
- VERSION = "0.0.4"
2
+ VERSION = "0.0.5"
3
3
  end
metadata CHANGED
@@ -1,12 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: biller_bot_resource
3
3
  version: !ruby/object:Gem::Version
4
- prerelease: false
5
- segments:
6
- - 0
7
- - 0
8
- - 4
9
- version: 0.0.4
4
+ prerelease:
5
+ version: 0.0.5
10
6
  platform: ruby
11
7
  authors:
12
8
  - Brad Seefeld
@@ -14,8 +10,7 @@ autorequire:
14
10
  bindir: bin
15
11
  cert_chain: []
16
12
 
17
- date: 2013-05-13 00:00:00 -07:00
18
- default_executable:
13
+ date: 2013-08-21 00:00:00 Z
19
14
  dependencies: []
20
15
 
21
16
  description: Provides a set of Ruby classes for interacting with the BillerBot API
@@ -42,7 +37,6 @@ files:
42
37
  - lib/biller_bot_resource/product.rb
43
38
  - lib/biller_bot_resource/resource.rb
44
39
  - lib/biller_bot_resource/version.rb
45
- has_rdoc: true
46
40
  homepage: https://github.com/bradseefeld/biller_bot_resource
47
41
  licenses: []
48
42
 
@@ -52,23 +46,21 @@ rdoc_options: []
52
46
  require_paths:
53
47
  - lib
54
48
  required_ruby_version: !ruby/object:Gem::Requirement
49
+ none: false
55
50
  requirements:
56
51
  - - ">="
57
52
  - !ruby/object:Gem::Version
58
- segments:
59
- - 0
60
53
  version: "0"
61
54
  required_rubygems_version: !ruby/object:Gem::Requirement
55
+ none: false
62
56
  requirements:
63
57
  - - ">="
64
58
  - !ruby/object:Gem::Version
65
- segments:
66
- - 0
67
59
  version: "0"
68
60
  requirements: []
69
61
 
70
62
  rubyforge_project: biller_bot_resource
71
- rubygems_version: 1.3.6
63
+ rubygems_version: 1.8.25
72
64
  signing_key:
73
65
  specification_version: 3
74
66
  summary: Common resources for the BillerBot API