Skip to content

Commit

Permalink
Fix TS lint-level error in mixins/-proxy.ts
Browse files Browse the repository at this point in the history
Explicitly do a consistent return from `unknownProperty`: if there is
no `content`, return `undefined.
  • Loading branch information
chriskrycho committed Apr 3, 2023
1 parent 7c6fec2 commit e927038
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/@ember/-internals/runtime/lib/mixins/-proxy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,7 @@ const ProxyMixin = Mixin.create({

unknownProperty(key: string) {
let content = contentFor(this);
if (content) {
return get(content, key);
}
return content ? get(content, key) : undefined;
},

setUnknownProperty(key: string, value: unknown) {
Expand Down

0 comments on commit e927038

Please sign in to comment.