Skip to content

Commit 6368b94

Browse files
committed
Merge branch 'main' into deprecate-metadata
2 parents 7ba6170 + 21f7c3d commit 6368b94

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

pkgs/native_assets_cli/lib/src/api/build_output.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ abstract final class BuildOutput {
6262
///
6363
/// In dry runs, the assets for all [Architecture]s for the [OS] specified in
6464
/// the dry run must be provided.
65-
Map<String, List<Asset>> get assetsForLinking;
65+
Map<String, Iterable<Asset>> get assetsForLinking;
6666

6767
/// The files used by this build.
6868
///

pkgs/native_assets_cli/lib/src/api/link_config.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ abstract class LinkConfig implements HookConfig {
4646
int? targetMacOSVersion,
4747
CCompilerConfig? cCompiler,
4848
BuildMode? buildMode,
49-
List<String>? supportedAssetTypes,
49+
Iterable<String>? supportedAssetTypes,
5050
int? targetAndroidNdkApi,
5151
required Iterable<Asset> assets,
5252
required LinkModePreference linkModePreference,
@@ -77,7 +77,7 @@ abstract class LinkConfig implements HookConfig {
7777
required String packageName,
7878
required Uri packageRoot,
7979
required OS targetOS,
80-
List<String>? supportedAssetTypes,
80+
Iterable<String>? supportedAssetTypes,
8181
required Iterable<Asset> assets,
8282
required LinkModePreference linkModePreference,
8383
Version? version,

pkgs/native_assets_cli/lib/src/api/link_output.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ abstract final class LinkOutput {
5454
void addAssets(Iterable<Asset> assets);
5555

5656
factory LinkOutput({
57-
List<AssetImpl>? assets,
57+
Iterable<AssetImpl>? assets,
5858
Dependencies? dependencies,
5959
DateTime? timestamp,
6060
}) =>

pkgs/native_assets_cli/lib/src/model/hook_output.dart

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,14 @@ final class HookOutputImpl implements BuildOutput, LinkOutput {
2929

3030
HookOutputImpl({
3131
DateTime? timestamp,
32-
List<AssetImpl>? assets,
32+
Iterable<AssetImpl>? assets,
3333
Map<String, List<AssetImpl>>? assetsForLinking,
3434
Dependencies? dependencies,
3535
Metadata? metadata,
3636
}) : timestamp = (timestamp ?? DateTime.now()).roundDownToSeconds(),
37-
_assets = assets ?? [],
37+
_assets = [
38+
...?assets,
39+
],
3840
_assetsForLinking = assetsForLinking ?? {},
3941
// ignore: prefer_const_constructors
4042
_dependencies = dependencies ?? Dependencies([]),

0 commit comments

Comments
 (0)