/**
   * Lists all buildings on the planet with the given location.
   *
   * @param player Player.
   * @param location Planet location.
   * @return All buildings on the planet.
   */
  @GET
  @ApiOperation(value = "Get all buildings on a planet")
  public BuildingsResponse getBuildings(
      @Auth @ApiParam(access = "internal") Player player,
      @PathParam("location") @ApiParam("Planet location") String location) {
    Preconditions.checkNotNull(player, "player");
    Preconditions.checkNotNull(location, "location");

    Planet planet = ResourceHelper.findPlanetWithLocationAndOwner(planetService, location, player);
    Buildings buildings = buildingService.findBuildingsOnPlanet(planet);

    return new BuildingsResponse(Functional.mapToList(buildings, BuildingMapper::fromBuilding));
  }