Skip to content

Commit

Permalink
prefixed country code variable name with an underscore
Browse files Browse the repository at this point in the history
  • Loading branch information
PatrickChrestin committed Jun 14, 2024
1 parent 74c1676 commit c521c13
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/generate.dart
Original file line number Diff line number Diff line change
Expand Up @@ -255,13 +255,13 @@ class CodegenLoader extends AssetLoader{
for (var file in files) {
final localeName =
path.basename(file.path).replaceFirst('.json', '').replaceAll('-', '_');
listLocales.add('"$localeName": $localeName');
listLocales.add('"$localeName": _$localeName');
final fileData = File(file.path);

Map<String, dynamic>? data = json.decode(await fileData.readAsString());

final mapString = const JsonEncoder.withIndent(' ').convert(data);
gFile += 'static const Map<String,dynamic> $localeName = $mapString;\n';
gFile += 'static const Map<String,dynamic> _$localeName = $mapString;\n';
}

gFile +=
Expand Down

0 comments on commit c521c13

Please sign in to comment.