• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3/**
4 * Error wrapper for SocksClient
5 */
6class SocksClientError extends Error {
7    constructor(message, options) {
8        super(message);
9        this.options = options;
10    }
11}
12exports.SocksClientError = SocksClientError;
13/**
14 * Shuffles a given array.
15 * @param array The array to shuffle.
16 */
17function shuffleArray(array) {
18    for (let i = array.length - 1; i > 0; i--) {
19        let j = Math.floor(Math.random() * (i + 1));
20        [array[i], array[j]] = [array[j], array[i]];
21    }
22}
23exports.shuffleArray = shuffleArray;
24//# sourceMappingURL=util.js.map