Throw error when updateProperties

Hi @himyyy,

you are trying to execute a command during the execute phase of another command. This is not possible and therefore causes this error.

Please use the CommandInterceptor. Here you can find an example which should solve your use case easily:

class DefaultElementName extends CommandInterceptor {
  constructor(eventBus, modeling) {
    super(eventBus);

    this.postExecute("shape.create", ({ context }) => {
      const { shape } = context;

      const { id } = shape;

      modeling.updateLabel(shape, id);
    });
  }
}