Spelling: ... wox (#3775)

* spelling: arguments

* spelling: config

* spelling: deactivated

* spelling: exception

* spelling: folder

* spelling: initialize

* spelling: makesure

* spelling: response

* spelling: storage

* spelling: visibility

* spelling: serialized

* spelling: zipped
This commit is contained in:
Josh Soref
2020-05-27 11:05:54 -04:00
committed by GitHub
parent c2c163ac4e
commit 84169cce10
19 changed files with 49 additions and 49 deletions

View File

@@ -10,7 +10,7 @@ namespace Wox.Infrastructure.Exception
{
public class ExceptionFormatter
{
public static string FormatExcpetion(System.Exception exception)
public static string FormatException(System.Exception exception)
{
return CreateExceptionReport(exception);
}

View File

@@ -9,7 +9,7 @@ namespace Wox.Infrastructure.Storage
/// <summary>
/// Serialize object using json format.
/// </summary>
public class JsonStrorage<T>
public class JsonStorage<T>
{
private readonly JsonSerializerSettings _serializerSettings;
private T _data;
@@ -20,7 +20,7 @@ namespace Wox.Infrastructure.Storage
public string DirectoryPath { get; set; }
internal JsonStrorage()
internal JsonStorage()
{
// use property initialization instead of DefaultValueAttribute
// easier and flexible for default value of object
@@ -35,10 +35,10 @@ namespace Wox.Infrastructure.Storage
{
if (File.Exists(FilePath))
{
var searlized = File.ReadAllText(FilePath);
if (!string.IsNullOrWhiteSpace(searlized))
var serialized = File.ReadAllText(FilePath);
if (!string.IsNullOrWhiteSpace(serialized))
{
Deserialize(searlized);
Deserialize(serialized);
}
else
{
@@ -52,16 +52,16 @@ namespace Wox.Infrastructure.Storage
return _data.NonNull();
}
private void Deserialize(string searlized)
private void Deserialize(string serialized)
{
try
{
_data = JsonConvert.DeserializeObject<T>(searlized, _serializerSettings);
_data = JsonConvert.DeserializeObject<T>(serialized, _serializerSettings);
}
catch (JsonException e)
{
LoadDefault();
Log.Exception($"|JsonStrorage.Deserialize|Deserialize error for json <{FilePath}>", e);
Log.Exception($"|JsonStorage.Deserialize|Deserialize error for json <{FilePath}>", e);
}
if (_data == null)

View File

@@ -2,7 +2,7 @@
namespace Wox.Infrastructure.Storage
{
public class PluginJsonStorage<T> :JsonStrorage<T> where T : new()
public class PluginJsonStorage<T> :JsonStorage<T> where T : new()
{
public PluginJsonStorage()
{

View File

@@ -7,7 +7,7 @@ using System.Threading.Tasks;
namespace Wox.Infrastructure.Storage
{
public class WoxJsonStorage<T> : JsonStrorage<T> where T : new()
public class WoxJsonStorage<T> : JsonStorage<T> where T : new()
{
public WoxJsonStorage()
{

View File

@@ -128,7 +128,7 @@ namespace Wox.Infrastructure.UserSettings
}
}
public bool LeaveCmdOpen { get; set; }
public bool HideWhenDeactive { get; set; } = true;
public bool HideWhenDeactivated { get; set; } = true;
public bool RememberLastLaunchLocation { get; set; }
public bool IgnoreHotkeysOnFullscreen { get; set; }