Skip to content
Discussion options

You must be logged in to vote

The throw statement is correct. The problem is the import in TrifidCipherEncode.mjs.

Your fork currently has:

import Operation from "../Operation.mjs";
import OperationError from "../Operation.mjs";

Change the second line to:

import OperationError from "../errors/OperationError.mjs";

At the moment, new OperationError(...) is actually constructing another instance of the ordinary Operation class. That constructor ignores the string and does not create an Error.message. Because the thrown object is not a real OperationError, CyberChef enters its generic error path and formats e.message, producing undefined.

No other registration or error configuration is needed. This is the same import used…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by TPTPWDotACoEMW
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants