@infrab4a/connect 3.3.1-beta.1 → 3.3.1-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -3598,7 +3598,7 @@
|
|
|
3598
3598
|
FindHasuraGraphQLMixin.prototype.find = function (params) {
|
|
3599
3599
|
var _a;
|
|
3600
3600
|
return __awaiter(this, void 0, void 0, function () {
|
|
3601
|
-
var _b, filters, limits, orderBy, options, enableCount, variablesCount, variables, result, data
|
|
3601
|
+
var _b, filters, limits, orderBy, options, enableCount, variablesCount, variables, result, data;
|
|
3602
3602
|
var _this = this;
|
|
3603
3603
|
return __generator(this, function (_c) {
|
|
3604
3604
|
switch (_c.label) {
|
|
@@ -3629,19 +3629,18 @@
|
|
|
3629
3629
|
variables: variables,
|
|
3630
3630
|
}
|
|
3631
3631
|
], __read((enableCount
|
|
3632
|
-
? [
|
|
3633
|
-
: [
|
|
3632
|
+
? [
|
|
3634
3633
|
{
|
|
3635
3634
|
operation: this.tableName + "_aggregate",
|
|
3636
3635
|
fields: [{ aggregate: ['count'] }],
|
|
3637
3636
|
variables: variablesCount,
|
|
3638
3637
|
},
|
|
3639
|
-
]
|
|
3638
|
+
]
|
|
3639
|
+
: []))))];
|
|
3640
3640
|
case 1:
|
|
3641
3641
|
result = _c.sent();
|
|
3642
3642
|
data = result[this.tableName].map(function (row) { return _this.convertDataFromHasura(row); });
|
|
3643
|
-
count
|
|
3644
|
-
return [2 /*return*/, { data: data, count: enableCount ? count : Infinity }];
|
|
3643
|
+
return [2 /*return*/, { data: data, count: enableCount ? result[this.tableName + "_aggregate"].aggregate.count : Infinity }];
|
|
3645
3644
|
}
|
|
3646
3645
|
});
|
|
3647
3646
|
});
|