// Copyright (c) 2009-2026 SAP SE, All Rights Reserved

/**
 * @fileOverview Custom Error class to transport more details
 */
sap.ui.define([
], (
) => {
    "use strict";

    class LaunchpadError extends Error {
        constructor (sMessage, oDetails, oOriginalError) {
            super(sMessage);
            this.name = "LaunchpadError";
            this.details = oDetails;
            this.originalError = oOriginalError;

            if (oOriginalError && oOriginalError.stack) {
                this.stack = oOriginalError.stack;
            }
        }
    }

    return LaunchpadError;
});
