main
js 21 lines 586 Bytes
Raw
1 /**
2 * Copyright (c) Meta Platforms, Inc. and affiliates.
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 *
7 * @flow
8 */
9
10 export default class UnsupportedBridgeOperationError extends Error {
11 constructor(message: string) {
12 super(message);
13
14 // Maintains proper stack trace for where our error was thrown (only available on V8)
15 if (Error.captureStackTrace) {
16 Error.captureStackTrace(this, UnsupportedBridgeOperationError);
17 }
18
19 this.name = 'UnsupportedBridgeOperationError';
20 }
21 }