title: How to apply switchMap by condition?
body: <p>I have the following rxjs:</p>
  <pre><code>let state = true;
  
    iif(
              () =&gt; this.mode === MODES.CREATE,
              this.applicationOrderParcelsRepository.create(data).pipe(switchMap(() =&gt; this.egrnService.SendRequestGetEGRP())),
              this.applicationOrderParcelsRepository.update(data),
          )
              .pipe(indicate(this.loading$), observableHandlerResponse(this.messageService))
              .subscribe((document) =&gt; {
                  this.changeDetection.detectChanges();
                  this.dialogRef.close(document);
              });
  </code></pre>
  <p>My problem is that I want to execute <code>this.egrnService.SendRequestGetEGRP()</code> only if first request is done and <code>state = true</code>. How to do that?</p>