Add null check and fix API reference 41/147441/1
authorJongkyu Koo <jk.koo@samsung.com>
Mon, 4 Sep 2017 09:55:36 +0000 (18:55 +0900)
committerJongkyu Koo <jk.koo@samsung.com>
Mon, 4 Sep 2017 09:55:36 +0000 (18:55 +0900)
Change-Id: If80eb959ff033b3d876e64ce966e401bcee46816
Signed-off-by: Jongkyu Koo <jk.koo@samsung.com>
src/Tizen.Pims.Contacts/Tizen.Pims.Contacts/ContactsQuery.cs

index 63cadcb..4bb4efd 100644 (file)
@@ -106,6 +106,11 @@ namespace Tizen.Pims.Contacts
         /// <exception cref="ArgumentException">Thrown when one of the arguments provided to a method is not valid</exception>
         public void SetProjection(uint[] propertyIdArray)
         {
+            if (propertyIdArray == null)
+            {
+                throw new ArgumentException("Invalid Parameters Provided");
+            }
+
             int error = Interop.Query.ContactsQuerySetProjection(_queryHandle, propertyIdArray, propertyIdArray.Length);
             if ((int)ContactsError.None != error)
             {
@@ -118,7 +123,6 @@ namespace Tizen.Pims.Contacts
         /// Sets the "distinct" option for projection.
         /// </summary>
         /// <param name="set">If true it is set, otherwise if false it is unset</param>
-        /// <exception cref="ArgumentException">Thrown when one of the arguments provided to a method is not valid</exception>
         public void SetDistinct(bool set)
         {
             int error = Interop.Query.ContactsQuerySetDistinct(_queryHandle, set);