Skip to content

Commit 4d188ff

Browse files
authored
Chagnes from preactjs/preact#4632 (#494)
1 parent 5f94f09 commit 4d188ff

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/adapter/10/bindings.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ export function getHookState(
136136
// useContext
137137
if (type === HookType.useContext) {
138138
const context = list[index]._context || list[index].__c || list[index].c;
139-
const provider = c.context[context._id] || c.context[context.__c] || c.context[context.__l];
139+
const provider = c.context[context._id] || c.context[context.__c];
140140
return provider
141141
? provider.props.value
142142
: context._defaultValue || context.__;
@@ -212,7 +212,7 @@ export function getDisplayName(vnode: VNode, config: RendererConfig): string {
212212

213213
// Provider
214214
if ((c as any).sub) {
215-
const ctx = (type as any)._contextRef || (type as any).__ || (type as any).__c;
215+
const ctx = (type as any)._contextRef || (type as any).__ || (type as any).__l;
216216
if (ctx && ctx.displayName) {
217217
return `${ctx.displayName}.Provider`;
218218
}

0 commit comments

Comments
 (0)