Global

Members

Array.<number>

# STATUS_CODES_TO_ABORT_ON

Defines an array of HTTP status codes that the application should not attempt to reconnect to Mastodon on.

Defines an array of HTTP status codes that the application should not attempt to reconnect to Mastodon on.

View Source settings.js, line 5

Methods

# attachBodyInfoToError(err, body)

Attach error information from the response body to the error object.

Attach error information from the response body to the error object.

Parameters:
Name Type Description
err Error

Error instance to which body info will be attached.

body Object

JSON object that is the deserialized HTTP response body received from Mastodon.

View Source helpers.js, line 29

# makeMastodonError(messageopt) → {Error}

Create a new Mastodon error object.

Create a new Mastodon error object.

Parameters:
Name Type Attributes Description
message string <optional>

Optional error message.

View Source helpers.js, line 51

A new error object.

Error

# moveParamsIntoPath(params, path) → {string}

For each /:param fragment in path, move the value in params at that key to path.

For each /:param fragment in path, move the value in params at that key to path. If the key is not found in params, throw.

Parameters:
Name Type Description
params Object

Object used to build path.

path string

String to transform.

View Source helpers.js, line 9

Modified path

string