Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Neo.CLI/CLI/MainService.Tools.cs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ private void OnParseCommand(string value)
[ParseFunction(".nef file path to content base64")]
private string? NefFileToBase64(string path)
{
if (Path.GetExtension(path).ToLower() != ".nef") return null;
if (!Path.GetExtension(path).Equals(".nef", StringComparison.CurrentCultureIgnoreCase)) return null;
if (!File.Exists(path)) return null;
return Convert.ToBase64String(File.ReadAllBytes(path));
}
Expand Down
2 changes: 1 addition & 1 deletion src/Neo.CLI/CLI/MainService.Wallet.cs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ private void OnCloseWalletCommand()
[ConsoleCommand("upgrade wallet", Category = "Wallet Commands")]
private void OnUpgradeWalletCommand(string path)
{
if (Path.GetExtension(path).ToLowerInvariant() != ".db3")
if (!Path.GetExtension(path).Equals(".db3", StringComparison.InvariantCultureIgnoreCase))
{
ConsoleHelper.Warning("Can't upgrade the wallet file. Check if your wallet is in db3 format.");
return;
Expand Down
2 changes: 1 addition & 1 deletion src/Neo/Wallets/NEP6/NEP6WalletFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class NEP6WalletFactory : IWalletFactory

public bool Handle(string path)
{
return Path.GetExtension(path).ToLowerInvariant() == ".json";
return Path.GetExtension(path).Equals(".json", StringComparison.InvariantCultureIgnoreCase);
}

public Wallet CreateWallet(string name, string path, string password, ProtocolSettings settings)
Expand Down
2 changes: 1 addition & 1 deletion src/Plugins/SQLiteWallet/SQLiteWalletFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public SQLiteWalletFactory()

public bool Handle(string path)
{
return GetExtension(path).ToLowerInvariant() == ".db3";
return GetExtension(path).Equals(".db3", StringComparison.InvariantCultureIgnoreCase);
}

public Wallet CreateWallet(string name, string path, string password, ProtocolSettings settings)
Expand Down
Loading