SPlit up
This commit is contained in:
parent
cf39ad754e
commit
f59d01227b
91 changed files with 10370 additions and 7562 deletions
|
|
@ -184,12 +184,19 @@ pub async fn get_postcode_stats(
|
|||
"GET /api/postcode-stats"
|
||||
);
|
||||
|
||||
let crime_latest_year = if crime_by_year.is_empty() {
|
||||
None
|
||||
} else {
|
||||
stats::crime_latest_available_year(&state.crime_by_year)
|
||||
};
|
||||
|
||||
Ok(HexagonStatsResponse {
|
||||
count: total_count,
|
||||
numeric_features,
|
||||
enum_features: enum_features_out,
|
||||
price_history,
|
||||
crime_by_year,
|
||||
crime_latest_year,
|
||||
central_postcode: None,
|
||||
filter_exclusions,
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue