feature: Treat warnings as errors and set warning level to 5 (#2270)
This commit is contained in:
@@ -7,6 +7,8 @@
|
||||
<Description>A Discord.Net extension adding support for bot commands.</Description>
|
||||
<TargetFrameworks Condition=" '$(OS)' == 'Windows_NT' ">net6.0;net5.0;net461;netstandard2.0;netstandard2.1</TargetFrameworks>
|
||||
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">net6.0;net5.0;netstandard2.0;netstandard2.1</TargetFrameworks>
|
||||
<WarningLevel>5</WarningLevel>
|
||||
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Discord.Net.Core\Discord.Net.Core.csproj" />
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace Discord.Commands
|
||||
{
|
||||
@@ -12,7 +12,7 @@ namespace Discord.Commands
|
||||
/// <summary>
|
||||
/// Gets on which pipeline stage the command may have matched or failed.
|
||||
/// </summary>
|
||||
public IResult? Pipeline { get; }
|
||||
public IResult Pipeline { get; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public CommandError? Error { get; }
|
||||
@@ -21,7 +21,7 @@ namespace Discord.Commands
|
||||
/// <inheritdoc />
|
||||
public bool IsSuccess => !Error.HasValue;
|
||||
|
||||
private MatchResult(CommandMatch? match, IResult? pipeline, CommandError? error, string errorReason)
|
||||
private MatchResult(CommandMatch? match, IResult pipeline, CommandError? error, string errorReason)
|
||||
{
|
||||
Match = match;
|
||||
Error = error;
|
||||
|
||||
Reference in New Issue
Block a user