Fixed Flow error
Brian Vaughn committed
Apr 23, 2019 at 11:32 UTC
4dcb34ea32dba72380720f65b2039b126d141e46
2 files changed
+3
-3
src/devtools/cache.js
+1
-1
@@ -13,7 +13,7 @@ import LRU from 'lru-cache';
13
// The size of this cache is bounded by how many renders were profiled,
14
// and it will be fully reset between profiling sessions.
15
16
-type Thenable<T> = {
16
+export type Thenable<T> = {
17
then(resolve: (T) => mixed, reject: (mixed) => mixed): mixed,
18
};
19
src/devtools/views/Components/InspectedElementContext.js
+2
-2
@@ -17,7 +17,7 @@ import type {
17
InspectedElement,
18
InspectedElementResponse,
19
} from 'src/devtools/views/Components/types';
20
-import type { Resource } from '../../cache';
20
+import type { Resource, Thenable } from '../../cache';
21
22
type Context = {|
23
read(id: number): InspectedElement | null,
@@ -28,7 +28,7 @@ InspectedElementContext.displayName = 'InspectedElementContext';
28
29
type ResolveFn = (inspectedElement: InspectedElement) => void;
30
type InProgressRequest = {|
31
- promise: Promise<InspectedElement>,
31
+ promise: Thenable<InspectedElement>,
32
resolveFn: ResolveFn,
33
|};
34