From 38e537d110b7c0162ee70e88015a35cd9d60f782 Mon Sep 17 00:00:00 2001 From: Jakub Butkiewicz Date: Thu, 21 Sep 2023 14:37:36 +0200 Subject: [PATCH] fix: resolve comments --- src/libs/ValidationUtils.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/libs/ValidationUtils.ts b/src/libs/ValidationUtils.ts index d01deed5f05a..962cb43fd43a 100644 --- a/src/libs/ValidationUtils.ts +++ b/src/libs/ValidationUtils.ts @@ -13,10 +13,10 @@ import {Report} from '../types/onyx'; * Implements the Luhn Algorithm, a checksum formula used to validate credit card * numbers. */ -function validateCardNumber(val: string): boolean { +function validateCardNumber(value: string): boolean { let sum = 0; - for (let i = 0; i < val.length; i++) { - let intVal = parseInt(val.substr(i, 1), 10); + for (let i = 0; i < value.length; i++) { + let intVal = parseInt(value.substr(i, 1), 10); if (i % 2 === 0) { intVal *= 2; if (intVal > 9) { @@ -235,7 +235,7 @@ function validateIdentity(identity: Record): Record