public async Task <JsonResponse <List <StructureType> > > GetStructureTypes() { List <StructureType> types; try { types = await _structureService.GetAllTypesAsync(); } catch (Exception) { return(new JsonResponse <List <StructureType> > { success = false, msg = "Unknown error fetching types" }); } return(new JsonResponse <List <StructureType> > { success = true, data = types }); }