Ejemplo n.º 1
0
 def check_if_corp_id_valid(id):
     logger.debug("Checking if %s %s is valid corp id" % (type(id), id))
     id = int(id)
     a = evelink.api.API()
     api = evelink.corp.Corp(a)
     try:
         result = api.corporation_sheet(corp_id=id).result
         logger.debug("Determined corp id %s is valid" % id)
         return True
     except:
         logger.debug("Determined corp id %s is invalid" % id)
         return False
Ejemplo n.º 2
0
 def check_if_corp_id_valid(id):
     logger.debug("Checking if %s %s is valid corp id" % (type(id), id))
     id = int(id)
     a = evelink.api.API()
     api = evelink.corp.Corp(a)
     try:
         result = api.corporation_sheet(corp_id=id).result
         logger.debug("Determined corp id %s is valid" % id)
         return True
     except:
         logger.debug("Determined corp id %s is invalid" % id)
         return False
Ejemplo n.º 3
0
 def check_id(self, id):
     logger.debug("Checking if %s %s is valid corp id" % (type(id), id))
     id = int(id)
     try:
         a = evelink.api.API()
         api = evelink.corp.Corp(a)
         result = api.corporation_sheet(corp_id=id).result
         logger.debug("Determined corp id %s is valid" % id)
         return True
     except evelink.api.APIError as e:
         if int(e.code) == 523:
             logger.debug("Determined corp id %s is invalid" % id)
             return False
         else:
             raise e
Ejemplo n.º 4
0
 def check_id(self, id):
     logger.debug("Checking if %s %s is valid corp id" % (type(id), id))
     id = int(id)
     try:
         a = evelink.api.API()
         api = evelink.corp.Corp(a)
         result = api.corporation_sheet(corp_id=id).result
         logger.debug("Determined corp id %s is valid" % id)
         return True
     except evelink.api.APIError as e:
         if int(e.code) == 523:
             logger.debug("Determined corp id %s is invalid" % id)
             return False
         else:
             raise e