MCPcopy Index your code
hub / github.com/loopbackio/loopback-next / assertNotInProcess

Method assertNotInProcess

packages/core/src/application.ts:266–271  ·  view source on GitHub ↗

* Assert there is no other operation is in progress, i.e., the state is not * `*ing`, such as `starting` or `stopping`. * * @param op - The operation name, such as 'boot', 'start', or 'stop'

(op: string)

Source from the content-addressed store, hash-verified

264 * @param op - The operation name, such as 'boot', 'start', or 'stop'
265 */
266 protected assertNotInProcess(op: string) {
267 assert(
268 !this._state.endsWith('ing'),
269 `Cannot ${op} the application as it is ${this._state}.`,
270 );
271 }
272
273 /**
274 * Assert current state of the application to be one of the expected values

Callers 4

initMethod · 0.95
startMethod · 0.95
stopMethod · 0.95
bootMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected