fix: correct region and subregion retrieval
- Update region access to use country.region instead of city.region - Update subregion access to use country.subregion instead of city.subregion These changes ensure that the region and subregion are accurately retrieved based on the correct geographical hierarchy, improving the data integrity of the application.
This commit is contained in:
parent
5de3d4306f
commit
9ff27cbe4d
@ -31,8 +31,8 @@ class RssController < ApplicationController
|
||||
country: format_as_tag(art.city&.country&.name),
|
||||
city: format_as_tag(art.city&.name),
|
||||
state: format_as_tag(art.city&.state&.name),
|
||||
region: format_as_tag(art.city&.region&.name),
|
||||
subregion: format_as_tag(art.city&.subregion&.name),
|
||||
region: format_as_tag(art.city&.country&.region&.name),
|
||||
subregion: format_as_tag(art.city&.country&.subregion&.name),
|
||||
description: art.description,
|
||||
prompt: art.prompt,
|
||||
date: art.weather_date&.strftime("%Y-%m-%d"),
|
||||
|
Loading…
Reference in New Issue
Block a user