Handle nullability

This commit is contained in:
j4ck 2022-06-04 19:11:47 +03:00
parent 72cf566049
commit f072749c0a
1 changed files with 4 additions and 1 deletions

View File

@ -86,7 +86,10 @@ public class Database
var tableToReturn = _tables.Find(x => x.Name == table);
var row = tableToReturn?.Rows?.FirstOrDefault(x => x.Columns?.FirstOrDefault(y => y.Name == key)?.Name == key);
var column = row?.Columns?.FirstOrDefault(x => x.Name == key);
if (column != null)
column.Value = value;
Save();
}