# Module: pTry

## Table of contents

### Promises Functions

- [default](pTry.md#default)

## Promises Functions

### default

▸ **default**(`fn`, `...args`): `Promise`<`any`\>

Executes the given function and always returns a promise, even if the function is synchronous.

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `fn` | `Function` |  |
| `...args` | `any`[] | Arguments |

#### Returns

`Promise`<`any`\>

#### Defined in

[src/pTry.js:10](https://github.com/Twipped/js-utils/blob/9c196e3/src/pTry.js#L10)
