Skip to content

Commit

Permalink
🎨 remove duplicate null-coalescing responseTypeReference
Browse files Browse the repository at this point in the history
  • Loading branch information
techouse committed Aug 29, 2024
1 parent 33372bf commit 7ace2dd
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions chopper_generator/lib/src/generator.dart
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,8 @@ final class ChopperGenerator

// Set Response with generic types
final Reference responseTypeReference = refer(
responseType?.getDisplayString(withNullability: false) ??
responseType?.getDisplayString(withNullability: false) ??
'dynamic');
responseType?.getDisplayString(withNullability: false) ?? 'dynamic',
);
// Set the return type
final returnType = isResponseObject
? refer(m.returnType.getDisplayString(withNullability: false))
Expand Down

0 comments on commit 7ace2dd

Please sign in to comment.