Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Small typo corrections #1897

Merged
merged 2 commits into from Jul 13, 2019
Merged
Changes from 1 commit
Commits
File filter...
Filter file types
Jump to…
Jump to file or symbol
Failed to load files and symbols.

Always

Just for now

@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
@@ -93,7 +93,7 @@ internal void Add(int value, int bitCount)
{
if (bitCount < 0 || bitCount > 32)
{
throw new ArgumentOutOfRangeException(nameof(bitCount), "bitCount must greater or equal to 0");
throw new ArgumentOutOfRangeException(nameof(bitCount), "bitCount must be greater than or equal to 0");
}

int numBitsLeft = bitCount;
@@ -3,7 +3,7 @@
namespace Gma.QrCodeNet.Encoding.EncodingRegion
{
/// <summary>
/// Embed version information for version larger or equal to 7.
/// Embed version information for version larger than or equal to 7.
/// </summary>
/// <remarks>ISO/IEC 18004:2000 Chapter 8.10 Page 54</remarks>
internal static class VersionInformation
@@ -13,7 +13,7 @@ internal static class VersionInformation

/// <summary>
/// Embed version information to Matrix
/// Only for version greater or equal to 7
/// Only for version greater than or equal to 7
/// </summary>
/// <param name="tsMatrix">Matrix</param>
/// <param name="version">version number</param>
@@ -1,10 +1,10 @@
namespace Gma.QrCodeNet.Encoding
namespace Gma.QrCodeNet.Encoding
{
/// <summary>
/// This class contain two variables.
/// BitMatrix for QrCode
/// isContainMatrix for indicate whether QrCode contains BitMatrix or not.
/// BitMatrix will equal to null if isContainMatrix is false.
/// BitMatrix will be equal to null if isContainMatrix is false.
/// </summary>
public class QrCode
{
@@ -41,7 +41,7 @@ public AllFeeEstimate(EstimateSmartFeeMode type, IDictionary<int, int> estimatio

public Money GetFeeRate(int feeTarget)
{
// Where the target is still under or equals to the the requested target.
// Where the target is still under or equals to the requested target.
int satoshiPerByte = Estimations
.Last(x => x.Key <= feeTarget) // The last should be the largest feeTarget.
.Value;
@@ -245,19 +245,19 @@ public int CompareTo(int other)
public static bool operator <(Height x, Height y) => x.Value < y.Value;

/// <summary>
/// Performs a comparison and return if left-side value is greater or equal to right-side value.
/// Performs a comparison and return if left-side value is greater than or equal to right-side value.
/// </summary>
/// <param name="x">The left-hand Height value to compare.</param>
/// <param name="y">The right-hand Height value to compare.</param>
/// <returns>true if left-hand value is greater or equal to right-side value; otherwise false.</returns>
/// <returns>true if left-hand value is greater than or equal to right-side value; otherwise false.</returns>
public static bool operator >=(Height x, Height y) => x.Value >= y.Value;

/// <summary>
/// Performs a comparison and return if left-side value is less or equal to right-side value.
/// Performs a comparison and return if left-side value is less than or equal to right-side value.
/// </summary>
/// <param name="x">The left-hand Height value to compare.</param>
/// <param name="y">The right-hand Height value to compare.</param>
/// <returns>true if left-hand value is less or equal to right-side value; otherwise false.</returns>
/// <returns>true if left-hand value is less than or equal to right-side value; otherwise false.</returns>
public static bool operator <=(Height x, Height y) => x.Value <= y.Value;

/// <summary>
@@ -293,35 +293,35 @@ public int CompareTo(int other)
public static bool operator <(Height x, int y) => x.Value < y;

/// <summary>
/// Performs a comparison and return if left-side value is greater or equal to right-side value.
/// Performs a comparison and return if left-side value is greater than or equal to right-side value.
/// </summary>
/// <param name="x">The left-hand Int32 value to compare.</param>
/// <param name="y">The right-hand Height value to compare.</param>
/// <returns>true if left-hand value is greater or equal to right-side value; otherwise false.</returns>
/// <returns>true if left-hand value is greater than or equal to right-side value; otherwise false.</returns>
public static bool operator >=(int x, Height y) => x >= y.Value;

/// <summary>
/// Performs a comparison and return if left-side value is less or equal to right-side value.
/// Performs a comparison and return if left-side value is less than or equal to right-side value.
/// </summary>
/// <param name="x">The left-hand Int32 value to compare.</param>
/// <param name="y">The right-hand Height value to compare.</param>
/// <returns>true if left-hand value is less or equal to right-side value; otherwise false.</returns>
/// <returns>true if left-hand value is less than or equal to right-side value; otherwise false.</returns>
public static bool operator <=(int x, Height y) => x <= y.Value;

/// <summary>
/// Performs a comparison and return if left-side value is greater or equal to right-side value.
/// Performs a comparison and return if left-side value is greater than or equal to right-side value.
/// </summary>
/// <param name="x">The left-hand Height value to compare.</param>
/// <param name="y">The right-hand Int32 value to compare.</param>
/// <returns>true if left-hand value is greater or equal to right-side value; otherwise false.</returns>
/// <returns>true if left-hand value is greater than or equal to right-side value; otherwise false.</returns>
public static bool operator >=(Height x, int y) => x.Value >= y;

/// <summary>
/// Performs a comparison and return if left-side value is less or equal to right-side value.
/// Performs a comparison and return if left-side value is less than or equal to right-side value.
/// </summary>
/// <param name="x">The left-hand Height value to compare.</param>
/// <param name="y">The right-hand Int32 value to compare.</param>
/// <returns>true if left-hand value is less or equal to right-side value; otherwise false.</returns>
/// <returns>true if left-hand value is less than or equal to right-side value; otherwise false.</returns>
public static bool operator <=(Height x, int y) => x.Value <= y;

#endregion EqualityAndComparison
@@ -183,7 +183,7 @@ protected Option(string prototype, string description, int maxValueCount, bool h

if (prototype.Length == 0)
{
throw new ArgumentException("Cannot be the empty string.", nameof(prototype));
throw new ArgumentException("Cannot be empty string.", nameof(prototype));
This conversation was marked as resolved by yahiheb

This comment has been minimized.

Copy link
@benthecarman

benthecarman Jul 12, 2019

Collaborator

I think a better alternative is "Cannot be an empty string."

This comment has been minimized.

Copy link
@yahiheb

yahiheb Jul 12, 2019

Author Collaborator

I agree.

}

if (maxValueCount < 0)
@@ -332,7 +332,7 @@ private async void Round_StatusChangedAsync(object sender, CcjRoundStatus status
// But it cannot be larger than the current anonset of that round.
newAnonymitySet = Math.Min(newAnonymitySet, nextRound.AnonymitySet);

// Only change the anonymity set of the next round if new anonset does not equal and newanonset larger than 1.
// Only change the anonymity set of the next round if new anonset does not equal and newanonset is larger than 1.
if (nextRound.AnonymitySet != newAnonymitySet && newAnonymitySet > 1)
{
nextRound.UpdateAnonymitySet(newAnonymitySet, syncLock: false);
@@ -226,7 +226,7 @@ public async Task<(Version ClientVersion, int BackendMajorVersion)> GetVersionsA
public async Task<(bool backendCompatible, bool clientUpToDate)> CheckUpdatesAsync(CancellationToken cancel)
{
var versions = await GetVersionsAsync(cancel);
var clientUpToDate = Helpers.Constants.ClientVersion >= versions.ClientVersion; // If the client version locally is greater or equal to the backend's reported client version, then good.
var clientUpToDate = Helpers.Constants.ClientVersion >= versions.ClientVersion; // If the client version locally is greater than or equal to the backend's reported client version, then good.
var backendCompatible = int.Parse(Helpers.Constants.BackendMajorVersion) == versions.BackendMajorVersion; // If the backend major and the client major equals, then our softwares are compatible.

return (backendCompatible, clientUpToDate);
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.