@@ -308,7 +308,7 @@ class PackageURL {
308308 // Split the remainder once from left on ':'.
309309 const colonIndex = purlStr . indexOf ( ':' )
310310 // Use WHATWG URL to split up the purl string.
311- /* c8 ignore next 3 -- Comment lines don't need coverage */
311+ /* c8 ignore next 3 -- Comment lines don't need coverage. */
312312 // - Split the purl string once from right on '#'
313313 // - Split the remainder once from right on '?'
314314 // - Split the remainder once from left on ':'
@@ -324,7 +324,7 @@ class PackageURL {
324324 const afterColon = purlStr . slice ( colonIndex + 1 )
325325 const trimmedAfterColon = trimLeadingSlashes ( afterColon )
326326 url = new URL ( `${ beforeColon } :${ trimmedAfterColon } ` )
327- /* c8 ignore next 4 -- V8 coverage sees multiple branch paths in ternary that can't all be tested */
327+ /* c8 ignore next 4 -- V8 coverage sees multiple branch paths in ternary that can't all be tested. */
328328 maybeUrlWithAuth =
329329 afterColon . length === trimmedAfterColon . length
330330 ? url
@@ -336,10 +336,10 @@ class PackageURL {
336336 }
337337 }
338338 // The scheme is a constant with the value "pkg".
339- /* c8 ignore next -- Tested: colonIndex === -1 (url undefined) case, but V8 can't see both branches */
339+ /* c8 ignore next -- Tested: colonIndex === -1 (url undefined) case, but V8 can't see both branches. */
340340 if ( url ?. protocol !== 'pkg:' ) {
341341 throw new PurlError ( 'missing required "pkg" scheme component' )
342- /* c8 ignore next -- Unreachable code after throw */
342+ /* c8 ignore next -- Unreachable code after throw. */
343343 }
344344 // A purl must NOT contain a URL Authority i.e. there is no support for
345345 // username, password, host and port components.
@@ -362,7 +362,7 @@ class PackageURL {
362362
363363 let rawVersion : string | undefined
364364 // Both branches of this ternary are tested, but V8 reports phantom branch combinations
365- /* c8 ignore start -- npm vs non-npm path logic both tested but V8 sees extra branches */
365+ /* c8 ignore start -- npm vs non-npm path logic both tested but V8 sees extra branches. */
366366 let atSignIndex =
367367 rawType === 'npm'
368368 ? // Deviate from the specification to handle a special npm purl type case for
@@ -419,7 +419,7 @@ class PackageURL {
419419 const value = decodePurlComponent ( 'qualifiers' , pairs . at ( 1 ) ?? '' )
420420 // Use URLSearchParams#append to preserve plus signs.
421421 // https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams#preserving_plus_signs
422- /* c8 ignore next -- URLSearchParams.append has internal V8 branches we can't control */
422+ /* c8 ignore next -- URLSearchParams.append has internal V8 branches we can't control. */
423423 searchParams . append ( pairs [ 0 ] ! , value )
424424 }
425425 // Split the remainder once from right on '?'.
0 commit comments