Skip to content

Commit 17d7ea8

Browse files
committed
add isNative flag to ResultWrapper
1 parent 889ad23 commit 17d7ea8

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

packages/cubejs-backend-native/js/ResultWrapper.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,13 @@ export class ResultWrapper {
77

88
public cached: Boolean = false;
99

10+
private readonly isNative: Boolean = false;
11+
1012
public constructor(private readonly nativeReference: any) {
13+
if (nativeReference) {
14+
this.isNative = true;
15+
}
16+
1117
this.proxy = new Proxy(this, {
1218
get: (target, prop: string | symbol) => {
1319
// intercept indexes
@@ -18,7 +24,7 @@ export class ResultWrapper {
1824

1925
// intercept isNative
2026
if (prop === 'isNative') {
21-
return true;
27+
return this.isNative;
2228
}
2329

2430
// intercept array props and methods

0 commit comments

Comments
 (0)