mirror of
https://github.com/zoriya/octokit.net.git
synced 2026-06-06 12:03:19 +00:00
Implement GetOrCreateApplicationAuthentication
Implements the endpoint for creating an application authorization token.
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
|
||||
namespace Octokit
|
||||
{
|
||||
public class TwoFactorChallengeResult
|
||||
{
|
||||
[SuppressMessage("Microsoft.Security", "CA2104:DoNotDeclareReadOnlyMutableReferenceTypes",
|
||||
Justification = "It really is immutable yo!")]
|
||||
public static readonly TwoFactorChallengeResult RequestResendCode = new TwoFactorChallengeResult(null, true);
|
||||
|
||||
public TwoFactorChallengeResult(string authenticationCode)
|
||||
: this(authenticationCode, false)
|
||||
{
|
||||
Ensure.ArgumentNotNull(authenticationCode, "authenticationCode");
|
||||
}
|
||||
|
||||
TwoFactorChallengeResult(string authenticationCode, bool resendCodeRequested)
|
||||
{
|
||||
AuthenticationCode = authenticationCode;
|
||||
ResendCodeRequested = resendCodeRequested;
|
||||
}
|
||||
|
||||
public bool ResendCodeRequested { get; private set; }
|
||||
|
||||
public string AuthenticationCode { get; private set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user