Skip to content

Commit b5f2b98

Browse files
committed
fix omit type in queries
1 parent eef6662 commit b5f2b98

File tree

4 files changed

+14
-3
lines changed

4 files changed

+14
-3
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# @proofgeist/fmdapi
22

3+
## 4.0.2
4+
5+
### Patch Changes
6+
7+
- fix omit type for queries
8+
39
## 4.0.1
410

511
### Patch Changes

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@proofgeist/fmdapi",
3-
"version": "4.0.1",
3+
"version": "4.0.2",
44
"description": "FileMaker Data API client",
55
"main": "dist/index.js",
66
"repository": "[email protected]:proofgeist/fm-dapi.git",

src/client-types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ export type Query<
205205
[key in keyof T]: T[key] | string;
206206
}> &
207207
Partial<{ [key in SecondLevelKeys<U>]?: string }> & {
208-
omit?: boolean;
208+
omit?: "true";
209209
};
210210

211211
export type LayoutMetadataResponse = {

test/client-methods.test.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,11 @@ describe("find methods", () => {
3838

3939
expect(Array.isArray(resp.data)).toBe(false);
4040
});
41+
it("find with omit", async () => {
42+
await layoutClient.find<{ anything: string }>({
43+
query: { anything: "anything", omit: "true" },
44+
});
45+
});
4146
});
4247

4348
describe("portal methods", () => {
@@ -67,7 +72,7 @@ describe("portal methods", () => {
6772
},
6873
});
6974
});
70-
it.only("should handle portal methods with strange names", async () => {
75+
it("should handle portal methods with strange names", async () => {
7176
const { data } = await weirdPortalClient.list({
7277
limit: 1,
7378
portalRanges: {

0 commit comments

Comments
 (0)