title: Flow block is not executing, call generated from ViewModel
body: <p>Can't understand why the flow block doesn't execute and control returns back to ViewModel.</p>
  <p>ViewModel code</p>
  <pre><code>fun getFilesFromServer() {
  
          viewModelScope.launch(Dispatchers.IO) {
  
              ftpRepository.getFilesFromServer()
                  .onEach { state -&gt;
  
                      when (state) {
                          is Resource.Loading -&gt; {
                              liveData.postValue(Resource.Loading())
                          }
  
                  }
          }
      }
  </code></pre>
  <p>Repository (Here the problem, control doesn't go inside flow {} block)</p>
  <pre><code>override suspend fun getFilesFromServer(): Flow&lt;Resource&lt;Response&gt;&gt; = flow {
  
      emit(Resource.Loading())
  
      ftpClient.connect(
          Constants.SERVER_IP, Constants.PORT,
          Constants.USER_NAME,
          Constants.PASSWORD,
          object : OnEZFtpCallBack&lt;Void?&gt; {
              override fun onSuccess(response: Void?) {
  
                  requestFtpFileList()
              }
  
              override fun onFail(code: Int, msg: String) {
                  
              }
          }
      )
  }
  </code></pre>
  <p>Thanks for your time...</p>