Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: isObject utils fn should return only boolean value (hyperlane-xy…
…z#4756) ### Description When `isObject` pass with param `null/undefined` it returns `null/undefined` We should strict return boolean value <!-- What's included in this PR? --> ### Drive-by changes ```diff export function isObject(item: any): boolean { - return item && typeof item === 'object' && !Array.isArray(item); + return !!item && typeof item === 'object' && !Array.isArray(item); } ``` <!-- Are there any minor or drive-by changes also included? --> ### Related issues <!-- - Fixes #[issue number here] --> ### Backward compatibility <!-- Are these changes backward compatible? Are there any infrastructure implications, e.g. changes that would prohibit deploying older commits using this infra tooling? Yes/No --> ### Testing Has updated with test `object.test.ts` <!-- What kind of testing have these changes undergone? None/Manual/Unit Tests -->
- Loading branch information