Fixes and sample
This commit is contained in:
@@ -5,11 +5,18 @@ namespace Darkmatter.Fonepay
|
||||
public sealed class FonepayError : Exception
|
||||
{
|
||||
public int ErrorCode { get; }
|
||||
public string Docs { get; }
|
||||
|
||||
public FonepayError(int errorCode, string message,
|
||||
string docs)
|
||||
public FonepayError(int errorCode, string message, string docs)
|
||||
: base(message)
|
||||
{
|
||||
ErrorCode = errorCode;
|
||||
Docs = docs ?? throw new ArgumentNullException(nameof(docs));
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return $"{base.ToString()} (ErrorCode: {ErrorCode}, Docs: {Docs})";
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user