Skip to content

Commit 7738cff

Browse files
committed
fix: dotnet
1 parent d80a1ba commit 7738cff

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

templates/dotnet/src/Appwrite/Query.cs.twig

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,16 @@ namespace Appwrite
1717
this.method = method;
1818
this.attribute = attribute;
1919

20-
if (values == null || values is IList)
20+
if (values is IList valuesList)
21+
{
22+
this.values = new List<object>();
23+
foreach (var value in valuesList)
24+
{
25+
this.values.Add(value); // Automatically boxes if value is a value type
26+
}
27+
}
28+
else if (values != null)
2129
{
22-
this.values = (List<object>?)values;
23-
} else {
2430
this.values = new List<object> { values };
2531
}
2632
}

0 commit comments

Comments
 (0)