(type: any, unmaskedContext: Object)
| 22 | } |
| 23 | |
| 24 | export function getMaskedContext(type: any, unmaskedContext: Object): Object { |
| 25 | if (disableLegacyContext) { |
| 26 | return emptyContextObject; |
| 27 | } else { |
| 28 | const contextTypes = type.contextTypes; |
| 29 | if (!contextTypes) { |
| 30 | return emptyContextObject; |
| 31 | } |
| 32 | |
| 33 | const context: {[string]: $FlowFixMe} = {}; |
| 34 | for (const key in contextTypes) { |
| 35 | context[key] = unmaskedContext[key]; |
| 36 | } |
| 37 | |
| 38 | return context; |
| 39 | } |
| 40 | } |
| 41 | |
| 42 | export function processChildContext( |
| 43 | instance: any, |
no outgoing calls
no test coverage detected