Ejemplo n.º 1
0
 def get_symbols(self,id):
     map = self._get_map_from_user_by_id(c.user, id)
     if map is None:
         abort(404)
     mapfile = Mapfile()
     mapfile.from_file(os.path.join(config['mapfiles_dir'], map.filepath))
     # prevent JSON Array Cross-site Exploits (XSRF/CSRF)
     return {'symbols': mapfile.get_symbols()}
Ejemplo n.º 2
0
 def get_symbols(self, id):
     map = self._get_map_from_user_by_id(c.user, id)
     if map is None:
         abort(404)
     mapfile = Mapfile()
     mapfile.from_file(os.path.join(config['mapfiles_dir'], map.filepath))
     # prevent JSON Array Cross-site Exploits (XSRF/CSRF)
     return {'symbols': mapfile.get_symbols()}