Skip to content

Commit

Permalink
Rename
Browse files Browse the repository at this point in the history
  • Loading branch information
mosuem committed Nov 13, 2024
1 parent 8454156 commit 0811388
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion pkgs/messages_builder/bin/messages_builder.dart
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Future<void> main(List<String> args) async {
final mapping = await MessageDataFileBuilder(
inputFolder: inputFolder,
outputFolder: outputFolder,
generationOptions: generationOptions,
options: generationOptions,
).run();

await MessageCallingCodeGenerator(
Expand Down
11 changes: 4 additions & 7 deletions pkgs/messages_builder/lib/message_data_builder.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ import 'message_file.dart';
class MessageDataFileBuilder {
final Directory inputFolder;
final Directory outputFolder;
final GenerationOptions generationOptions;
final GenerationOptions options;

MessageDataFileBuilder({
required this.inputFolder,
required this.outputFolder,
required this.generationOptions,
required this.options,
});

Future<Map<String, String>> run() async {
Expand All @@ -41,12 +41,9 @@ class MessageDataFileBuilder {
print('Generating $arbFilePath, bundle this in your assets.');
final arbFileUri = Uri.file(arbFilePath);
final arbFileContents = await File.fromUri(arbFileUri).readAsString();
final messageBundle = await parseMessageFile(
arbFileContents,
generationOptions,
);
final messageBundle = await parseMessageFile(arbFileContents, options);

final serializer = JsonSerializer(generationOptions.findById);
final serializer = JsonSerializer(options.findById);

final data = _arbToData(messageBundle, arbFilePath, serializer);

Expand Down

0 comments on commit 0811388

Please sign in to comment.