Skip to content

Commit 4bfbb6d

Browse files
authored
Merge pull request #121 from duckdb/jray/accept-null-or-undef-for-logical-type-alias
accept null or undefined for logical type alias
2 parents 7bf4079 + 62cd753 commit 4bfbb6d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

api/src/DuckDBLogicalType.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -145,8 +145,8 @@ export class DuckDBLogicalType {
145145
public get alias(): string | undefined {
146146
return duckdb.logical_type_get_alias(this.logical_type) || undefined;
147147
}
148-
public set alias(newAlias: string) {
149-
duckdb.logical_type_set_alias(this.logical_type, newAlias);
148+
public set alias(newAlias: string | null | undefined) {
149+
duckdb.logical_type_set_alias(this.logical_type, newAlias || '');
150150
}
151151
public asType(): DuckDBType {
152152
const alias = this.alias;

0 commit comments

Comments
 (0)