Advertisement
Guest User

Untitled

a guest
Nov 26th, 2014
708
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.48 KB | None | 0 0
  1. def CATEGORIES():
  2.     account_linked = False
  3.     user_api_key = my_addon.getSetting('api_key')
  4. #    if user_api_key:
  5. #        response = urllib2.urlopen(API_PATH + '/chats/?api_key=' + user_api_key + '&format=json')
  6. #        data = simplejson.loads(response.read())
  7. #        if data['status_code'] == 100:
  8. #            # Revert to the default key
  9. #            my_addon.setSetting('api_key', '')
  10. #        else:
  11.     global API_KEY
  12.     API_KEY = user_api_key
  13.     account_linked = True
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement