@react-pakistan/util-functions 1.24.86 → 1.24.89
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.
|
@@ -159,9 +159,9 @@ var updatePayment = function (_a) { return __awaiter(void 0, [_a], void 0, funct
|
|
|
159
159
|
return __generator(this, function (_c) {
|
|
160
160
|
switch (_c.label) {
|
|
161
161
|
case 0:
|
|
162
|
-
if (!id) {
|
|
163
|
-
|
|
164
|
-
}
|
|
162
|
+
// if (!id) {
|
|
163
|
+
// throw new Error('Payment ID is required');
|
|
164
|
+
// }
|
|
165
165
|
if (!amount ||
|
|
166
166
|
!currency ||
|
|
167
167
|
!date ||
|
|
@@ -184,7 +184,7 @@ var updatePayment = function (_a) { return __awaiter(void 0, [_a], void 0, funct
|
|
|
184
184
|
};
|
|
185
185
|
where = { id: id };
|
|
186
186
|
return [4 /*yield*/, prisma.payment.upsert({
|
|
187
|
-
create: __assign({
|
|
187
|
+
create: __assign({}, paymentData),
|
|
188
188
|
update: paymentData,
|
|
189
189
|
where: where,
|
|
190
190
|
})];
|