Skip to content

Commit f8daf3b

Browse files
committed
chore(core): cleanup the xState logs for subscription
1 parent c834993 commit f8daf3b

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

packages/core/index.ts

-11
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,6 @@ const createInstallMachine = (initialContext: InstallMachineContext) => {
264264
},
265265
done: {
266266
type: 'final',
267-
entry: () => logWithColoredPrefix('stapler', 'Installation process completed!'),
268267
},
269268
failed: {
270269
type: 'final',
@@ -455,8 +454,6 @@ export const createProject = async (options: ProjectOptions, projectDir: string)
455454
let state: StaplerState = initializeState(projectDir, name, usePayload);
456455
state.options = options;
457456

458-
const currentDir = process.cwd();
459-
460457
const context: InstallMachineContext = {
461458
type: 'install',
462459
projectDir: projectDir,
@@ -466,13 +463,5 @@ export const createProject = async (options: ProjectOptions, projectDir: string)
466463
const installMachine = createInstallMachine(context);
467464
const installActor = createActor(installMachine);
468465

469-
installActor.subscribe((state: StateFrom<typeof installMachine>) => {
470-
if (state.matches('done')) {
471-
logWithColoredPrefix('stapler', 'Installation process completed!');
472-
} else if (state.matches('failed')) {
473-
console.error('Installation process failed.');
474-
}
475-
});
476-
477466
installActor.start();
478467
};

0 commit comments

Comments
 (0)