@naturalcycles/abba 1.9.1 → 1.9.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.
- package/dist/abba.js +1 -1
- package/package.json +1 -1
- package/src/abba.ts +2 -2
package/dist/abba.js
CHANGED
|
@@ -160,7 +160,7 @@ class Abba {
|
|
|
160
160
|
};
|
|
161
161
|
const buckets = await this.bucketDao.getBy('experimentId', experimentId);
|
|
162
162
|
await (0, js_lib_1.pMap)(buckets, async (bucket) => {
|
|
163
|
-
statistics[bucket.id] = await this.userAssignmentDao
|
|
163
|
+
statistics.buckets[bucket.id] = await this.userAssignmentDao
|
|
164
164
|
.query()
|
|
165
165
|
.filterEq('bucketId', bucket.id)
|
|
166
166
|
.runQueryCount();
|
package/package.json
CHANGED
package/src/abba.ts
CHANGED
|
@@ -213,7 +213,7 @@ export class Abba {
|
|
|
213
213
|
* Cold method.
|
|
214
214
|
*/
|
|
215
215
|
async getExperimentAssignmentStatistics(experimentId: number): Promise<AssignmentStatistics> {
|
|
216
|
-
const statistics = {
|
|
216
|
+
const statistics: AssignmentStatistics = {
|
|
217
217
|
sampled: await this.userAssignmentDao
|
|
218
218
|
.query()
|
|
219
219
|
.filterEq('experimentId', experimentId)
|
|
@@ -223,7 +223,7 @@ export class Abba {
|
|
|
223
223
|
|
|
224
224
|
const buckets = await this.bucketDao.getBy('experimentId', experimentId)
|
|
225
225
|
await pMap(buckets, async bucket => {
|
|
226
|
-
statistics[bucket.id] = await this.userAssignmentDao
|
|
226
|
+
statistics.buckets[bucket.id] = await this.userAssignmentDao
|
|
227
227
|
.query()
|
|
228
228
|
.filterEq('bucketId', bucket.id)
|
|
229
229
|
.runQueryCount()
|