Open Source Wealth Management Software. Angular + NestJS + Prisma + Nx + TypeScript 🤍
TypeScript angularetffinancefintechghostfoliohacktoberfestinvestingnestjsosspersonal-financeportfolioprismasoftwarestocktrackertradingtypescriptwealth-managementweb
Bugfix/fix parse date in date helper (#3675)
Thomas Kaul26277803c699
diff --git a/libs/common/src/lib/helper.ts b/libs/common/src/lib/helper.tsindex eb0fce2021..689150b68a 100644--- a/libs/common/src/lib/helper.ts+++ b/libs/common/src/lib/helper.ts@@ -350,7 +350,11 @@ export function isDerivedCurrency(aCurrency: string) {});}-export function parseDate(date: string): Date | null {+export function parseDate(date: string): Date {+ if (!date) {+ return undefined;+ }+// Transform 'yyyyMMdd' format to supported format by parse functionif (date?.length === 8) {const match = date.match(/^(\d{4})(\d{2})(\d{2})$/);