@@ -419,8 +419,8 @@ private static bool TryMapCommandTypesFromMethod(
419
419
commandClassType = "global::CommunityToolkit.Mvvm.Input.RelayCommand" ;
420
420
delegateType = "global::System.Action" ;
421
421
supportsCancellation = false ;
422
- commandTypeArguments = ImmutableArray . Create ( parameter . Type . GetFullyQualifiedName ( ) ) ;
423
- delegateTypeArguments = ImmutableArray . Create ( parameter . Type . GetFullyQualifiedName ( ) ) ;
422
+ commandTypeArguments = ImmutableArray . Create ( parameter . Type . GetFullyQualifiedNameWithNullabilityAnnotations ( ) ) ;
423
+ delegateTypeArguments = ImmutableArray . Create ( parameter . Type . GetFullyQualifiedNameWithNullabilityAnnotations ( ) ) ;
424
424
425
425
return true ;
426
426
}
@@ -453,7 +453,7 @@ private static bool TryMapCommandTypesFromMethod(
453
453
delegateType = "global::System.Func" ;
454
454
supportsCancellation = true ;
455
455
commandTypeArguments = ImmutableArray < string > . Empty ;
456
- delegateTypeArguments = ImmutableArray . Create ( singleParameter . Type . GetFullyQualifiedName ( ) , "global::System.Threading.Tasks.Task" ) ;
456
+ delegateTypeArguments = ImmutableArray . Create ( "global::System.Threading.CancellationToken" , "global::System.Threading.Tasks.Task" ) ;
457
457
458
458
return true ;
459
459
}
@@ -463,8 +463,8 @@ private static bool TryMapCommandTypesFromMethod(
463
463
commandClassType = "global::CommunityToolkit.Mvvm.Input.AsyncRelayCommand" ;
464
464
delegateType = "global::System.Func" ;
465
465
supportsCancellation = false ;
466
- commandTypeArguments = ImmutableArray . Create ( singleParameter . Type . GetFullyQualifiedName ( ) ) ;
467
- delegateTypeArguments = ImmutableArray . Create ( singleParameter . Type . GetFullyQualifiedName ( ) , "global::System.Threading.Tasks.Task" ) ;
466
+ commandTypeArguments = ImmutableArray . Create ( singleParameter . Type . GetFullyQualifiedNameWithNullabilityAnnotations ( ) ) ;
467
+ delegateTypeArguments = ImmutableArray . Create ( singleParameter . Type . GetFullyQualifiedNameWithNullabilityAnnotations ( ) , "global::System.Threading.Tasks.Task" ) ;
468
468
469
469
return true ;
470
470
}
@@ -479,8 +479,8 @@ private static bool TryMapCommandTypesFromMethod(
479
479
commandClassType = "global::CommunityToolkit.Mvvm.Input.AsyncRelayCommand" ;
480
480
delegateType = "global::System.Func" ;
481
481
supportsCancellation = true ;
482
- commandTypeArguments = ImmutableArray . Create ( firstParameter . Type . GetFullyQualifiedName ( ) ) ;
483
- delegateTypeArguments = ImmutableArray . Create ( firstParameter . Type . GetFullyQualifiedName ( ) , secondParameter . Type . GetFullyQualifiedName ( ) , "global::System.Threading.Tasks.Task" ) ;
482
+ commandTypeArguments = ImmutableArray . Create ( firstParameter . Type . GetFullyQualifiedNameWithNullabilityAnnotations ( ) ) ;
483
+ delegateTypeArguments = ImmutableArray . Create ( firstParameter . Type . GetFullyQualifiedNameWithNullabilityAnnotations ( ) , "global::System.Threading.CancellationToken" , "global::System.Threading.Tasks.Task" ) ;
484
484
485
485
return true ;
486
486
}
0 commit comments