Enable nullable reference types for MediaBrowser.Common

This commit is contained in:
Bond_009
2021-05-05 12:57:01 +02:00
parent 48e81e65e8
commit 91c2a57b28
43 changed files with 78 additions and 64 deletions

View File

@@ -1,5 +1,3 @@
#nullable enable
using System;
using System.Security.Cryptography;
using System.Text;

View File

@@ -1,5 +1,3 @@
#nullable enable
using System.Collections.Generic;
namespace MediaBrowser.Common.Extensions

View File

@@ -17,7 +17,7 @@ namespace MediaBrowser.Common.Extensions
{
return (context.Connection.LocalIpAddress == null
&& context.Connection.RemoteIpAddress == null)
|| context.Connection.LocalIpAddress.Equals(context.Connection.RemoteIpAddress);
|| Equals(context.Connection.LocalIpAddress, context.Connection.RemoteIpAddress);
}
/// <summary>

View File

@@ -1,5 +1,3 @@
#nullable enable
using System;
namespace MediaBrowser.Common.Extensions

View File

@@ -1,5 +1,3 @@
#nullable enable
using System;
using System.Diagnostics;
using System.Threading;

View File

@@ -1,4 +1,3 @@
#nullable enable
#pragma warning disable CS1591
using System;

View File

@@ -1,5 +1,3 @@
#nullable enable
using System;
namespace MediaBrowser.Common.Extensions

View File

@@ -1,5 +1,3 @@
#nullable enable
using System;
using System.Collections.Generic;

View File

@@ -21,7 +21,7 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
#nullable enable
#pragma warning disable CS1591
#pragma warning disable CA1034
using System;

View File

@@ -1,5 +1,3 @@
#nullable enable
using System.Collections.Generic;
using System.IO;
using System.Linq;