File tree Expand file tree Collapse file tree 1 file changed +10
-9
lines changed
apps/execution-service/src/execution Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -58,9 +58,9 @@ export class ExecutionService {
5858 }
5959
6060 // Cleanup function
61- const cleanup = async ( ) => {
61+ const cleanup = ( ) => {
6262 try {
63- await fs . rm ( tempDir , { recursive : true , force : true } ) ;
63+ fsSync . rmSync ( tempDir , { recursive : true , force : true } ) ;
6464 } catch ( error ) {
6565 console . error ( 'Cleanup error:' , error ) ;
6666 }
@@ -149,21 +149,22 @@ export class ExecutionService {
149149 if ( compileCommand ) {
150150 executeProcess ( compileCommand , ( compileResult ) => {
151151 if ( ! compileResult . success ) {
152- cleanup ( ) . finally ( ( ) => {
153- resolve ( {
154- success : false ,
155- output : 'Compilation Error: ' + compileResult . output ,
156- } ) ;
152+ cleanup ( ) ;
153+ resolve ( {
154+ success : false ,
155+ output : 'Compilation Error: ' + compileResult . output ,
157156 } ) ;
158157 } else {
159158 executeProcess ( runCommand , ( runResult ) => {
160- cleanup ( ) . finally ( ( ) => resolve ( runResult ) ) ;
159+ cleanup ( ) ;
160+ resolve ( runResult ) ;
161161 } ) ;
162162 }
163163 } ) ;
164164 } else {
165165 executeProcess ( runCommand , ( runResult ) => {
166- cleanup ( ) . finally ( ( ) => resolve ( runResult ) ) ;
166+ cleanup ( ) ;
167+ resolve ( runResult ) ;
167168 } ) ;
168169 }
169170 } ) ;
You can’t perform that action at this time.
0 commit comments