File tree Expand file tree Collapse file tree 4 files changed +5
-5
lines changed
AspNetCore/OData/src/Asp.Versioning.OData.ApiExplorer/ApiExplorer
Client/src/Asp.Versioning.Http.Client
Common.OData.ApiExplorer/OData Expand file tree Collapse file tree 4 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -107,6 +107,6 @@ private static ODataApiVersionCollectionProvider CollateApiVersions(
107107
108108 private sealed class ODataApiVersionCollectionProvider : IODataApiVersionCollectionProvider
109109 {
110- required public IReadOnlyList < ApiVersion > ApiVersions { get ; set ; }
110+ public required IReadOnlyList < ApiVersion > ApiVersions { get ; set ; }
111111 }
112112}
Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ public ApiVersionHandler(
3030 ApiVersion apiVersion ,
3131 IApiNotification ? notification = default ,
3232 IApiVersionParser ? parser = default ,
33- ApiVersionHeaderEnumerable ? enumerable = default )
33+ ApiVersionHeaderEnumerable ? enumerable = default )
3434 {
3535 this . apiVersionWriter = apiVersionWriter ?? throw new ArgumentNullException ( nameof ( apiVersionWriter ) ) ;
3636 this . apiVersion = apiVersion ?? throw new ArgumentNullException ( nameof ( apiVersion ) ) ;
@@ -75,7 +75,7 @@ protected virtual bool IsDeprecatedApi( HttpResponseMessage response )
7575 foreach ( var reportedApiVersion in enumerable . Deprecated ( response , parser ) )
7676 {
7777 // don't use '==' operator because a derived type may not overload it
78- if ( apiVersion . CompareTo ( reportedApiVersion ) == 0 )
78+ if ( apiVersion . Equals ( reportedApiVersion ) )
7979 {
8080 return true ;
8181 }
Original file line number Diff line number Diff line change @@ -23,6 +23,6 @@ public class ODataValue<T>
2323#if NETFRAMEWORK
2424 public T Value { get ; set ; } = default ! ;
2525#else
26- required public T Value { get ; set ; }
26+ public required T Value { get ; set ; }
2727#endif
2828}
Original file line number Diff line number Diff line change @@ -21,6 +21,6 @@ public class ODataId
2121#if NETFRAMEWORK
2222 public Uri Value { get ; set ; } = default ! ;
2323#else
24- required public Uri Value { get ; set ; }
24+ public required Uri Value { get ; set ; }
2525#endif
2626}
You can’t perform that action at this time.
0 commit comments