mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-20 23:06:16 -04:00
Fix highlighting not working
This commit is contained in:
parent
d6a80b4865
commit
34b7c47533
1 changed files with 4 additions and 1 deletions
|
@ -663,7 +663,10 @@ class WorkerWaiter {
|
||||||
* @param {number} pos.end - The end offset.
|
* @param {number} pos.end - The end offset.
|
||||||
*/
|
*/
|
||||||
highlight(recipeConfig, direction, pos) {
|
highlight(recipeConfig, direction, pos) {
|
||||||
const workerIdx = this.addChefWorker();
|
let workerIdx = this.getInactiveChefWorker(false);
|
||||||
|
if (workerIdx === -1) {
|
||||||
|
workerIdx = this.addChefWorker();
|
||||||
|
}
|
||||||
if (workerIdx === -1) return;
|
if (workerIdx === -1) return;
|
||||||
this.chefWorkers[workerIdx].worker.postMessage({
|
this.chefWorkers[workerIdx].worker.postMessage({
|
||||||
action: "highlight",
|
action: "highlight",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue