Permalink
Browse files

Quick vreme fix

  • Loading branch information...
1 parent c675e3e commit 12a3416074442d9dd6c6908b4d6a8fb3e63d121d @CrazyLemon CrazyLemon committed Dec 19, 2016
Showing with 1 addition and 1 deletion.
  1. +1 −1 scripts/vreme.coffee
View
@@ -104,7 +104,7 @@ module.exports = (bot) ->
cached_time_geo = 356 * 24 * 60 * 60 #1 leto
url_geo = "http://maps.googleapis.com/maps/api/geocode/json?address=#{encodeURI(key)},%20slovenija&sensor=true"
bot.fetchJSONCached redis, cached_time_geo, url_geo, (res) ->
- if res? # ne najde kraja
+ if res.status == "ZERO_RESULTS" # ne najde kraja
vreme key, (msg)->
cb "#{key}: #{msg}"
else #najde kraj

0 comments on commit 12a3416

Please sign in to comment.