weibo_2 0.0.8 → 0.0.9
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/weibo_2/access_token.rb +2 -2
- data/lib/weibo_2/version.rb +1 -1
- metadata +1 -1
data/lib/weibo_2/access_token.rb
CHANGED
@@ -6,14 +6,14 @@ module WeiboOAuth2
|
|
6
6
|
end
|
7
7
|
|
8
8
|
def expired?
|
9
|
-
expires? && (expires_at <
|
9
|
+
expires? && (expires_at < time_convertion(Time.now, '+08:00').to_i)
|
10
10
|
end
|
11
11
|
|
12
12
|
|
13
13
|
#Convert Time from a time zone to another time zone
|
14
14
|
#'+08:00' or '-08:00'
|
15
15
|
#return Time
|
16
|
-
def
|
16
|
+
def time_convertion(time, time_zone)
|
17
17
|
time.getutc.getlocal(time_zone)
|
18
18
|
end
|
19
19
|
end
|
data/lib/weibo_2/version.rb
CHANGED