MCPcopy Index your code
hub / github.com/MALSync/MALSync / runAsync

Method runAsync

src/chibiScript/ChibiConsumer.ts:76–88  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

74 }
75
76 async runAsync() {
77 if (this.hasRun) {
78 throw new ChibiError('Run method can only be executed once');
79 }
80 this.hasRun = true;
81 const state = await this._subroutineAsync(this.script);
82
83 if (state && state instanceof ChibiReturn) {
84 return state.getValue();
85 }
86
87 return state;
88 }
89
90 async _subroutineAsync(script: ChibiJson<any>, startState: any = null) {
91 this.ctx.setAsyncContext(true);

Callers

nothing calls this directly

Calls 2

_subroutineAsyncMethod · 0.95
getValueMethod · 0.45

Tested by

no test coverage detected