/// <summary> /// Updates the status bar with info about how fresh the search results are /// </summary> private async Task UpdateFreshnessInfoAsync(SearchLocation location) { var scanAges = await _db.GetScanAgesAsync(location.Path); if (scanAges.Any()) { var oldest = scanAges.Max(item => item.Value); tslStatus.Text = $"Last scanned {oldest.Humanize()} ago"; } else { tslStatus.Text = "Not scanned before"; } }
public override bool Equals(object obj) { SearchLocation test = obj as SearchLocation; return((test != null) ? (test.Name?.ToLower() ?? string.Empty).Equals(Name?.ToLower() ?? string.Empty) : false); }