mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-23 00:06:17 -04:00
Changed all error returns to OperationErrors
This commit is contained in:
parent
b3ee251ee3
commit
2e4f5b7070
25 changed files with 88 additions and 35 deletions
|
@ -7,6 +7,7 @@
|
|||
import Operation from "../Operation";
|
||||
import Utils from "../Utils";
|
||||
import {fromBase64, toBase64} from "../lib/Base64";
|
||||
import OperationError from "../errors/OperationError";
|
||||
|
||||
/**
|
||||
* Show Base64 offsets operation
|
||||
|
@ -58,7 +59,7 @@ class ShowBase64Offsets extends Operation {
|
|||
script = "<script type='application/javascript'>$('[data-toggle=\"tooltip\"]').tooltip()</script>";
|
||||
|
||||
if (input.length < 1) {
|
||||
return "Please enter a string.";
|
||||
throw new OperationError("Please enter a string.");
|
||||
}
|
||||
|
||||
// Highlight offset 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue