Skip to content

Commit

Permalink
Fix record types when using unionAsync as key
Browse files Browse the repository at this point in the history
  • Loading branch information
fabian-hiller committed Nov 29, 2023
1 parent f7e1b73 commit c607b3d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions library/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ All notable changes to the library will be documented in this file.
## vX.X.X (Month DD, YYYY)

- Add support for boolean to `notValue` validation (pull request #261)
- Fix `RecordInput` and `RecordOuput` type when using `unionAsync` as key

## v0.21.0 (November 19, 2023)

Expand Down
5 changes: 3 additions & 2 deletions library/src/schemas/record/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import type {
} from '../../types/index.ts';
import type { EnumSchema, EnumSchemaAsync } from '../enum/index.ts';
import type { PicklistSchema, PicklistSchemaAsync } from '../picklist/index.ts';
import type { UnionSchema } from '../union/index.ts';
import type { UnionSchema, UnionSchemaAsync } from '../union/index.ts';
import type { RecordKey } from './record.ts';
import type { RecordKeyAsync } from './recordAsync.ts';

Expand All @@ -29,7 +29,8 @@ type PartialKeySchema =
| PicklistSchemaAsync<any>
| EnumSchema<any>
| EnumSchemaAsync<any>
| UnionSchema<any>;
| UnionSchema<any>
| UnionSchemaAsync<any>;

/**
* Record input inference type.
Expand Down

0 comments on commit c607b3d

Please sign in to comment.