fanforce 0.3.7 → 0.3.8
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/fanforce/main.rb +7 -3
- data/lib/fanforce/version.rb +1 -1
- metadata +1 -1
data/lib/fanforce/main.rb
CHANGED
@@ -6,9 +6,13 @@ class Fanforce
|
|
6
6
|
include Fanforce::Utils
|
7
7
|
attr_reader :params
|
8
8
|
########################################################################
|
9
|
-
def initialize(
|
10
|
-
|
11
|
-
|
9
|
+
def initialize(arg={})
|
10
|
+
if arg.is_a?(Hash)
|
11
|
+
add_params(arg)
|
12
|
+
auth(@params) if @params.length > 0
|
13
|
+
elsif arg.is_a?(String)
|
14
|
+
auth(arg)
|
15
|
+
end
|
12
16
|
end
|
13
17
|
|
14
18
|
def add_params(params)
|
data/lib/fanforce/version.rb
CHANGED