Skip to content

Commit

Permalink
refactor: Use null instead of undefined.
Browse files Browse the repository at this point in the history
  • Loading branch information
gonfunko committed Oct 2, 2024
1 parent ce7eb3c commit 8bdd930
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions core/flyout_base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -937,12 +937,12 @@ export abstract class Flyout
* Returns the inflater responsible for constructing items of the given type.
*
* @param type The type of flyout content item to provide an inflater for.
* @returns An inflater object for the given type, or undefined if no inflater
* @returns An inflater object for the given type, or null if no inflater
* is registered for that type.
*/
protected getInflaterForType(type: string): IFlyoutInflater | undefined {
protected getInflaterForType(type: string): IFlyoutInflater | null {
if (this.inflaters.has(type)) {
return this.inflaters.get(type);
return this.inflaters.get(type) ?? null;
}

const InflaterClass = registry.getClass(
Expand All @@ -955,7 +955,7 @@ export abstract class Flyout
return inflater;
}

return undefined;
return null;
}
}

Expand Down

0 comments on commit 8bdd930

Please sign in to comment.