---
editLink: false
lastUpdated: false
---

[@salesforce/b2c-tooling-sdk](../../../modules.md) / [operations/logs](../index.md) / extractPaths

# Function: extractPaths()

> **extractPaths**(`message`): `string`[]

Defined in: [packages/b2c-tooling-sdk/src/operations/logs/path-normalizer.ts:230](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/e7c16f1ae423da0aa47b3e10be88f9770b53619b/packages/b2c-tooling-sdk/src/operations/logs/path-normalizer.ts#L230)

Extracts all cartridge paths from a message.

Useful for testing or analysis of log messages.

## Parameters

### message

`string`

Log message to extract paths from

## Returns

`string`[]

Array of extracted paths

## Example

```typescript
const paths = extractPaths("Error at (app_storefront/cartridge/controllers/Home.js:45)");
// Returns: ["app_storefront/cartridge/controllers/Home.js:45"]
```
