Skip to content

Commit 674c4ed

Browse files
committed
lint
1 parent 51d2188 commit 674c4ed

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/apps/wallet-admin/src/home/tabs/payments/PaymentsTab.tsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -267,19 +267,14 @@ const ListView: FC<ListViewProps> = (props: ListViewProps) => {
267267
}, [fetchWinnings])
268268

269269
const onPaymentEditCallback = useCallback((payment: Winning) => {
270-
let status = payment.status
271-
272270
setConfirmFlow({
273271
action: 'Save',
274272
callback: async () => {
275273
updatePayment(payment.id)
276274
},
277275
content: (
278276
<PaymentEditForm
279-
payment={{
280-
...payment,
281-
status,
282-
}}
277+
payment={payment}
283278
canSave={setIsConfirmFormValid}
284279
onValueUpdated={handleValueUpdated}
285280
/>

src/apps/wallet-admin/src/lib/components/payment-edit/PaymentEdit.tsx

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,9 +179,14 @@ const PaymentEdit: React.FC<PaymentEditFormProps> = (props: PaymentEditFormProps
179179

180180
const options = useCallback(() => {
181181
if (props.payment.status.toUpperCase() !== 'PAID') {
182-
const isMemberHold = ['On Hold (Member)', 'On Hold (Tax Form)', 'On Hold (Payment Provider)'].indexOf(props.payment.status) !== -1;
182+
const isMemberHold = [
183+
'On Hold (Member)',
184+
'On Hold (Tax Form)',
185+
'On Hold (Payment Provider)',
186+
].includes(props.payment.status)
187+
183188
return [
184-
...(isMemberHold ? [{label: props.payment.status, value: props.payment.status}] : []),
189+
...(isMemberHold ? [{ label: props.payment.status, value: props.payment.status }] : []),
185190
{ label: 'Owed', value: 'Owed' },
186191
{ label: 'On Hold (Admin)', value: 'On Hold (Admin)' },
187192
{ label: 'Cancel', value: 'Cancel' },

0 commit comments

Comments
 (0)