NullReferenceException

This commit is contained in:
2022-08-13 11:19:08 -07:00
parent 3aeab88384
commit 0392de1920
33 changed files with 1278 additions and 1030 deletions

View File

@ -24,15 +24,15 @@ public sealed class FaceEncoding : DisposableObject, ISerializable
private FaceEncoding(SerializationInfo info, StreamingContext context)
{
if (info == null)
throw new ArgumentNullException(nameof(info));
throw new NullReferenceException(nameof(info));
double[]? array = info.GetValue(nameof(_Encoding), typeof(double[])) as double[];
int? row = (int?)info.GetValue(nameof(_Encoding.Rows), typeof(int));
int? column = (int?)info.GetValue(nameof(_Encoding.Columns), typeof(int));
if (row is null)
throw new ArgumentNullException(nameof(row));
throw new NullReferenceException(nameof(row));
if (column is null)
throw new ArgumentNullException(nameof(column));
throw new NullReferenceException(nameof(column));
_Encoding = new Matrix<double>(array, row.Value, column.Value);
}