Skip to content

Commit

Permalink
fix: resolve deprecation warning regarding whereNotNull
Browse files Browse the repository at this point in the history
  • Loading branch information
JKRhb committed Oct 23, 2024
1 parent 26878dd commit 6cbbd6a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/src/core/definitions/security/combo_security_scheme.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
//
// SPDX-License-Identifier: BSD-3-Clause

import "package:collection/collection.dart";
import "package:curie/curie.dart";

import "../extensions/json_parser.dart";
Expand Down Expand Up @@ -51,7 +50,7 @@ final class ComboSecurityScheme extends SecurityScheme {
);

final count =
[oneOf, allOf].whereNotNull().fold(0, (previous, _) => previous + 1);
[oneOf, allOf].nonNulls.fold(0, (previous, _) => previous + 1);

if (count != 1) {
throw FormatException(
Expand Down

0 comments on commit 6cbbd6a

Please sign in to comment.