Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(locale): remove invalid city patterns from pt_BR #1913

Merged
merged 1 commit into from
Mar 7, 2023

Conversation

matthewmayer
Copy link
Contributor

> allFakers.pt_BR.location.city()
// 'undefined Hugo'

This is because two of the patterns for city reference city_prefix, but this is empty for pt_PT
https://github.com/faker-js/faker/blob/next/src/locales/pt_BR/location/city_prefix.ts

Removed these patterns

@matthewmayer matthewmayer requested a review from a team as a code owner March 7, 2023 17:39
@matthewmayer matthewmayer self-assigned this Mar 7, 2023
@codecov
Copy link

codecov bot commented Mar 7, 2023

Codecov Report

Merging #1913 (4065ecb) into next (cf2ce68) will increase coverage by 0.00%.
The diff coverage is n/a.

Additional details and impacted files
@@           Coverage Diff           @@
##             next    #1913   +/-   ##
=======================================
  Coverage   99.62%   99.62%           
=======================================
  Files        2356     2356           
  Lines      236565   236563    -2     
  Branches     1190     1194    +4     
=======================================
+ Hits       235670   235687   +17     
+ Misses        873      854   -19     
  Partials       22       22           
Impacted Files Coverage Δ
src/locales/pt_BR/location/city.ts 100.00% <ø> (ø)
src/modules/internet/user-agent.ts 92.60% <0.00%> (+5.62%) ⬆️

@import-brain import-brain added p: 1-normal Nothing urgent c: locale Permutes locale definitions m: location Something is referring to the location module labels Mar 7, 2023
@ST-DDT ST-DDT requested review from a team March 7, 2023 21:04
@xDivisionByZerox
Copy link
Member

xDivisionByZerox commented Mar 7, 2023

Should we remove the city_prefix.ts file (in this locale) entirely?

@ST-DDT
Copy link
Member

ST-DDT commented Mar 7, 2023

Should we remove the city_prefix.ts file (in this locale) entirely?

I think the empty array here is a marker that these data are intentionally missing instead of just being missing.

@ST-DDT ST-DDT merged commit 7ae5cdb into faker-js:next Mar 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: locale Permutes locale definitions m: location Something is referring to the location module p: 1-normal Nothing urgent
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

4 participants