2
0
mirror of https://github.com/9ParsonsB/Pulsar.git synced 2025-04-05 17:39:39 -04:00

Allow omit of explicit true in complex criteria ()

This commit is contained in:
Jonathan Miller 2022-12-21 10:02:06 -03:30 committed by GitHub
parent 229e76b87d
commit f9341c8cd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions
ObservatoryExplorer
ObservatoryHerald

@ -315,10 +315,14 @@ namespace Observatory.Explorer
try
{
var result = criteriaFunction.Value.Call(scan, parents, scanList, bioSignals, geoSignals);
if (result.Length > 0 && ((bool?)result[0]).GetValueOrDefault(false))
if (result.Length == 3 && ((bool?)result[0]).GetValueOrDefault(false))
{
results.Add((result[1].ToString(), result[2].ToString(), false));
}
else if (result.Length == 2)
{
results.Add((result[0].ToString(), result[1].ToString(), false));
}
}
catch (NLua.Exceptions.LuaScriptException e)
{

@ -61,7 +61,7 @@ namespace Observatory.Herald {
}
/// <summary>
/// Looks up a localized string similar to e698cf7e-0fbc-4e9a-b6a4-2480381afcc1.
/// Looks up a localized string similar to .
/// </summary>
internal static string ApiKey {
get {