Lint-fix all files in app
This commit is contained in:
@@ -55,7 +55,7 @@ interface MessageState {
|
||||
export class StreamingMessageParser {
|
||||
#messages = new Map<string, MessageState>();
|
||||
|
||||
constructor(private _options: StreamingMessageParserOptions = {}) { }
|
||||
constructor(private _options: StreamingMessageParserOptions = {}) {}
|
||||
|
||||
parse(messageId: string, input: string) {
|
||||
let state = this.#messages.get(messageId);
|
||||
@@ -120,20 +120,20 @@ export class StreamingMessageParser {
|
||||
i = closeIndex + ARTIFACT_ACTION_TAG_CLOSE.length;
|
||||
} else {
|
||||
if ('type' in currentAction && currentAction.type === 'file') {
|
||||
let content = input.slice(i);
|
||||
const content = input.slice(i);
|
||||
|
||||
this._options.callbacks?.onActionStream?.({
|
||||
artifactId: currentArtifact.id,
|
||||
messageId,
|
||||
actionId: String(state.actionId - 1),
|
||||
action: {
|
||||
...currentAction as FileAction,
|
||||
...(currentAction as FileAction),
|
||||
content,
|
||||
filePath: currentAction.filePath,
|
||||
},
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
@@ -272,7 +272,7 @@ export class StreamingMessageParser {
|
||||
}
|
||||
|
||||
(actionAttributes as FileAction).filePath = filePath;
|
||||
} else if (!(['shell', 'start'].includes(actionType))) {
|
||||
} else if (!['shell', 'start'].includes(actionType)) {
|
||||
logger.warn(`Unknown action type '${actionType}'`);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user