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

Correct members' names #1808

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

Always

Just for now

Correct members' names

  • Loading branch information...
yahiheb committed Jul 6, 2019
commit c16e1c96a08e33a55a8075be2942603643d8bf78
@@ -502,30 +502,30 @@ private static void Publish()
var hwiFolder = new DirectoryInfo(Path.Combine(currentBinDistDirectory, "Hwi", "Software"));
// Remove Tor binaries those are not relevant to the platform.
var torFolder = new DirectoryInfo(Path.Combine(currentBinDistDirectory, "TorDaemons"));
var toNotremove = "";
var toNotRemove = "";
if (target.StartsWith("win"))
{
toNotremove = "win";
toNotRemove = "win";
}
else if (target.StartsWith("linux"))
{
toNotremove = "linux";
toNotRemove = "linux";
}
else if (target.StartsWith("osx"))
{
toNotremove = "osx";
toNotRemove = "osx";
}
foreach (var file in torFolder.EnumerateFiles().Concat(hwiFolder.EnumerateFiles()))
{
if (!file.Name.Contains("data", StringComparison.OrdinalIgnoreCase) && !file.Name.Contains(toNotremove, StringComparison.OrdinalIgnoreCase))
if (!file.Name.Contains("data", StringComparison.OrdinalIgnoreCase) && !file.Name.Contains(toNotRemove, StringComparison.OrdinalIgnoreCase))
{
File.Delete(file.FullName);
}
}

foreach (var dir in hwiFolder.EnumerateDirectories())
{
if (!dir.Name.Contains(toNotremove, StringComparison.OrdinalIgnoreCase))
if (!dir.Name.Contains(toNotRemove, StringComparison.OrdinalIgnoreCase))
{
IoHelpers.DeleteRecursivelyWithMagicDustAsync(dir.FullName).GetAwaiter().GetResult();
}
@@ -387,9 +387,9 @@ bool IsStringArraysEqual(string[] lines1, string[] lines2)
for (int i = 0; i < lines1.Length; i++)
{
string line = lines2[i];
var readline = lines1[i];
var readLine = lines1[i];

if (!line.Equals(readline))
if (!line.Equals(readLine))
{
return false;
}
@@ -346,19 +346,19 @@ public static bool TryGetExtPubKeyFromFile(string filePath, out ExtPubKey extPub
}

// Example text to handle: "ExtPubKey": "03BF8271268000000013B9013C881FE456DDF524764F6322F611B03CF6".
var extpubkeyline = File.ReadLines(filePath) // Enumerated read.
var extPubKeyLine = File.ReadLines(filePath) // Enumerated read.
.Take(21) // Limit reads to x lines.
.FirstOrDefault(line => line.Contains("\"ExtPubKey\": \"", StringComparison.OrdinalIgnoreCase));

if (string.IsNullOrEmpty(extpubkeyline))
if (string.IsNullOrEmpty(extPubKeyLine))
{
return false;
}

var parts = extpubkeyline.Split("\"ExtPubKey\": \"");
var parts = extPubKeyLine.Split("\"ExtPubKey\": \"");
if (parts.Length != 2)
{
throw new FormatException($"Could not split line: {extpubkeyline}");
throw new FormatException($"Could not split line: {extPubKeyLine}");
}

var xpub = parts[1].TrimEnd(',', '"');
@@ -566,15 +566,15 @@ public ExtKey GetMasterExtKey(string password)
try
{
Key secret = EncryptedSecret.GetKey(password);
var extkey = new ExtKey(secret, ChainCode);
var extKey = new ExtKey(secret, ChainCode);

// Backwards compatibility:
if (MasterFingerprint is null)
{
MasterFingerprint = secret.PubKey.GetHDFingerPrint();
}

return extkey;
return extKey;
}
catch (SecurityException ex)
{
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.