Skip to content

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

Merged
ST-DDT merged 1 commit intofaker-js:nextfrom
matthewmayer:locale/pt-br-city-patterns
Mar 7, 2023
Merged

fix(locale): remove invalid city patterns from pt_BR#1913
ST-DDT merged 1 commit intofaker-js:nextfrom
matthewmayer:locale/pt-br-city-patterns

Conversation

@matthewmayer
Copy link
Copy Markdown
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
Copy Markdown

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%) ⬆️

@ejcheng ejcheng added p: 1-normal Nothing urgent c: locale Permutes locale definitions m: location Something is referring to the location module labels Mar 7, 2023
@ejcheng ejcheng added this to the v8.0 - Module Re-Shuffling milestone Mar 7, 2023
@ST-DDT ST-DDT requested review from a team March 7, 2023 21:04
@xDivisionByZerox
Copy link
Copy Markdown
Member

xDivisionByZerox commented Mar 7, 2023

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

@ST-DDT
Copy link
Copy Markdown
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.

4 participants