Modify isAwareOfContainerLifecycle to include function-type instances
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Garrett Mills 2023-07-16 14:45:09 -05:00
parent 743e81ae94
commit 9a55623370

View File

@ -48,7 +48,7 @@ export interface AwareOfContainerLifecycle {
export function isAwareOfContainerLifecycle(what: unknown): what is AwareOfContainerLifecycle {
return Boolean(
typeof what === 'object'
(typeof what === 'object' || typeof what === 'function')
&& what !== null
&& hasOwnProperty(what, 'awareOfContainerLifecycle')
&& what.awareOfContainerLifecycle,