@bbearai/core 0.2.9 → 0.2.10
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/index.js +7 -1
- package/dist/index.mjs +7 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -180,7 +180,7 @@ var BugBearClient = class {
|
|
|
180
180
|
console.error("BugBear: Failed to fetch assignments", error);
|
|
181
181
|
return [];
|
|
182
182
|
}
|
|
183
|
-
|
|
183
|
+
const mapped = (data || []).map((item) => ({
|
|
184
184
|
id: item.id,
|
|
185
185
|
status: item.status,
|
|
186
186
|
startedAt: item.started_at,
|
|
@@ -213,6 +213,12 @@ var BugBearClient = class {
|
|
|
213
213
|
} : void 0
|
|
214
214
|
}
|
|
215
215
|
}));
|
|
216
|
+
mapped.sort((a, b) => {
|
|
217
|
+
if (a.isVerification && !b.isVerification) return -1;
|
|
218
|
+
if (!a.isVerification && b.isVerification) return 1;
|
|
219
|
+
return 0;
|
|
220
|
+
});
|
|
221
|
+
return mapped;
|
|
216
222
|
} catch (err) {
|
|
217
223
|
console.error("BugBear: Error fetching assignments", err);
|
|
218
224
|
return [];
|
package/dist/index.mjs
CHANGED
|
@@ -151,7 +151,7 @@ var BugBearClient = class {
|
|
|
151
151
|
console.error("BugBear: Failed to fetch assignments", error);
|
|
152
152
|
return [];
|
|
153
153
|
}
|
|
154
|
-
|
|
154
|
+
const mapped = (data || []).map((item) => ({
|
|
155
155
|
id: item.id,
|
|
156
156
|
status: item.status,
|
|
157
157
|
startedAt: item.started_at,
|
|
@@ -184,6 +184,12 @@ var BugBearClient = class {
|
|
|
184
184
|
} : void 0
|
|
185
185
|
}
|
|
186
186
|
}));
|
|
187
|
+
mapped.sort((a, b) => {
|
|
188
|
+
if (a.isVerification && !b.isVerification) return -1;
|
|
189
|
+
if (!a.isVerification && b.isVerification) return 1;
|
|
190
|
+
return 0;
|
|
191
|
+
});
|
|
192
|
+
return mapped;
|
|
187
193
|
} catch (err) {
|
|
188
194
|
console.error("BugBear: Error fetching assignments", err);
|
|
189
195
|
return [];
|