Skip to content

Commit 315bf8a

Browse files
authored
Add ? to nullable (#2014)
I believe the cases are current reversed.
1 parent 93694d9 commit 315bf8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

working/macros/example/data_class.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ macro class _CopyWith implements ClassDeclarationsMacro {
123123
var namedParams = [
124124
for (var field in allFields)
125125
ParameterCode.fromString(
126-
'${field.type.toCode()}${field.type.isNullable ? '' : '?'} '
126+
'${field.type.toCode()}${field.type.isNullable ? '?' : ''} '
127127
'${field.name}'),
128128
];
129129
var args = [

0 commit comments

Comments
 (0)