refactor: handle non numeric comparisons

This commit is contained in:
Carlos Valente
2025-01-22 19:55:51 +01:00
committed by Carlos Valente
parent efe5ac16f2
commit 8ba65fa2bd
4 changed files with 119 additions and 52 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
/**
* Extracts a value from a nested object using a dot-separated path
*/
export function getPropertyFromPath<T extends object>(path: string, obj: T): any | undefined {
export function getPropertyFromPath<T extends object>(path: string, obj: T): unknown | undefined {
const keys = path.split('.');
let result: any = obj;