diff --git a/packages/graphql_codegen/lib/src/printer/base/equality.dart b/packages/graphql_codegen/lib/src/printer/base/equality.dart index 3b52dcd..7e77112 100644 --- a/packages/graphql_codegen/lib/src/printer/base/equality.dart +++ b/packages/graphql_codegen/lib/src/printer/base/equality.dart @@ -28,7 +28,7 @@ Method printEqualityOperator( ..statements = ListBuilder([ Code("if (identical(this, other)) {return true;}"), Code( - "if (!(other is ${name}) || runtimeType != other.runtimeType) {return false;}"), + "if (other is! ${name} || runtimeType != other.runtimeType) {return false;}"), ...properties.expand( (e) { final localThisName =