Skip to content

Commit

Permalink
fix: accept and convert in operator arrays
Browse files Browse the repository at this point in the history
  • Loading branch information
rsodre committed Jan 13, 2025
1 parent a50c3d1 commit 48f5f3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/sdk/src/convertQuerytoClause.ts
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,8 @@ function convertToPrimitive(value: any): torii.MemberValue {
};
} else if (typeof value === "string") {
return { String: value };
} else if (Array.isArray(value)) {
return { List: value.map((item) => convertToPrimitive(item)) };
}

// Add more type conversions as needed
Expand Down
2 changes: 2 additions & 0 deletions packages/sdk/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,8 @@ export type WhereCondition<TModel> =
$gte?: TModel[P];
$lt?: TModel[P];
$lte?: TModel[P];
$in?: TModel[P][];
$nin?: TModel[P][];
};
};

Expand Down

0 comments on commit 48f5f3c

Please sign in to comment.