fix(all): Fix answers with dialog id working again.
This commit is contained in:
parent
a9256d8ecb
commit
ec172b0554
3 changed files with 10 additions and 1 deletions
|
@ -37,6 +37,7 @@ import { GBServer } from '../../../src/app.js';
|
||||||
import Fs from 'fs';
|
import Fs from 'fs';
|
||||||
import SwaggerClient from 'swagger-client';
|
import SwaggerClient from 'swagger-client';
|
||||||
import { spawn } from 'child_process';
|
import { spawn } from 'child_process';
|
||||||
|
import { CodeServices } from '../../gpt.gblib/services/CodeServices.js';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Web Automation services of conversation to be called by BASIC.
|
* Web Automation services of conversation to be called by BASIC.
|
||||||
|
@ -138,6 +139,11 @@ export class DebuggerService {
|
||||||
GBServer.globals.debuggers[botId].breaks.push(Number.parseInt(line));
|
GBServer.globals.debuggers[botId].breaks.push(Number.parseInt(line));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public async refactor({ botId, code, change }) {
|
||||||
|
const service = new CodeServices();
|
||||||
|
return await service.refactor(code, change);
|
||||||
|
}
|
||||||
|
|
||||||
public async resume({ botId }) {
|
public async resume({ botId }) {
|
||||||
if (GBServer.globals.debuggers[botId].state === 2) {
|
if (GBServer.globals.debuggers[botId].state === 2) {
|
||||||
const client = GBServer.globals.debuggers[botId].client;
|
const client = GBServer.globals.debuggers[botId].client;
|
||||||
|
|
|
@ -36,7 +36,7 @@ import { GBSSR }from '../../core.gbapp/services/GBSSR.js';
|
||||||
|
|
||||||
export class CodeServices {
|
export class CodeServices {
|
||||||
|
|
||||||
public static async refactor (code, whatToDo) {
|
public async refactor (code, whatToDo) {
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -337,6 +337,9 @@ export class AskDialog extends IGBDialog {
|
||||||
const mainName = GBVMService.getMethodNameFromVBSFilename(text);
|
const mainName = GBVMService.getMethodNameFromVBSFilename(text);
|
||||||
await step.endDialog();
|
await step.endDialog();
|
||||||
return await GBVMService.callVM(mainName, min, step, user, this.deployer, false);
|
return await GBVMService.callVM(mainName, min, step, user, this.deployer, false);
|
||||||
|
}
|
||||||
|
else if (text.startsWith('/')) {
|
||||||
|
return await step.replaceDialog(text, { answer: answer });
|
||||||
} else {
|
} else {
|
||||||
await service.sendAnswer(min, AskDialog.getChannel(step), step, answer);
|
await service.sendAnswer(min, AskDialog.getChannel(step), step, answer);
|
||||||
return await step.replaceDialog('/ask', { isReturning: true });
|
return await step.replaceDialog('/ask', { isReturning: true });
|
||||||
|
|
Loading…
Add table
Reference in a new issue