diff --git a/packages/react-devtools-shared/src/backend/console.js b/packages/react-devtools-shared/src/backend/console.js index 0e54fa59a13b8..42b08a7205bf2 100644 --- a/packages/react-devtools-shared/src/backend/console.js +++ b/packages/react-devtools-shared/src/backend/console.js @@ -30,7 +30,7 @@ import { getStackByFiberInDevAndProd, getOwnerStackByFiberInDev, supportsOwnerStacks, - supportsNativeConsoleTasks, + supportsConsoleTasks, } from './fiber/DevToolsFiberComponentStack'; import {formatOwnerStack} from './shared/DevToolsOwnerStack'; import {castBool, castBrowserTheme} from '../utils'; @@ -251,7 +251,7 @@ export function patch({ if ( consoleSettingsRef.appendComponentStack && - !supportsNativeConsoleTasks(current) + !supportsConsoleTasks(current) ) { const enableOwnerStacks = supportsOwnerStacks(current); let componentStack = ''; diff --git a/packages/react-devtools-shared/src/backend/fiber/DevToolsFiberComponentStack.js b/packages/react-devtools-shared/src/backend/fiber/DevToolsFiberComponentStack.js index 5b34cfb0bd4fb..5a1fc4ee5337d 100644 --- a/packages/react-devtools-shared/src/backend/fiber/DevToolsFiberComponentStack.js +++ b/packages/react-devtools-shared/src/backend/fiber/DevToolsFiberComponentStack.js @@ -108,7 +108,7 @@ export function getStackByFiberInDevAndProd( } } -export function supportsNativeConsoleTasks(fiber: Fiber): boolean { +export function supportsConsoleTasks(fiber: Fiber): boolean { // If this Fiber supports native console.createTask then we are already running // inside a native async stack trace if it's active - meaning the DevTools is open. // Ideally we'd detect if this task was created while the DevTools was open or not.