소스 검색

Fixed app crash when CoreRepository shells are not initialised properly.

Frank van den Bos 9 달 전
부모
커밋
22d53704c1
1개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 3 3
      InABox.Mobile/InABox.Mobile.Shared/DataModels/Shell.cs

+ 3 - 3
InABox.Mobile/InABox.Mobile.Shared/DataModels/Shell.cs

@@ -119,9 +119,9 @@ namespace InABox.Mobile
 
             if (_row != null)
             {
-                var col = _columns.IndexOf(property);
-                var value = Row.Get<T>(col); //() Row.Values[];
-                return value;
+                var col = _columns?.IndexOf(property);
+                if (col != null)
+                    return Row.Get<T>(col.Value); //() Row.Values[];
             }
 
             return CoreUtils.GetDefault<T>();