MCPcopy
hub / github.com/ThatGuySam/doesitarm / firstNonEmptyString

Function firstNonEmptyString

helpers/scanner/scan.ts:128–132  ·  view source on GitHub ↗
( values: unknown[] )

Source from the content-addressed store, hash-verified

126}
127
128function firstNonEmptyString ( values: unknown[] ) {
129 const match = values.find( value => isNonEmptyString( value ) )
130
131 return typeof match === 'string' ? match : ''
132}
133
134function isPromiseLike<T> ( value: unknown ): value is PromiseLike<T> {
135 return Boolean( value ) && typeof ( value as PromiseLike<T> ).then === 'function'

Callers 1

findTargetFilesMethod · 0.85

Calls 1

isNonEmptyStringFunction · 0.90

Tested by

no test coverage detected