title: RecyclerView item not updated with LiveData
body: <p>I have an application using databinding, livedata, room, kotlin koroutines, viewmodel, navigation component and dagger.
  I have one activity, and two fragments.</p>
  
  <p>ListFragment: Show in a recyclerview a list of items.</p>
  
  <p>DetalFragment: Show the item detail, and can update some fields of the item with a save button.</p>
  
  <p>The problem is when I update some fields from detailfragment, then the changes isn´t visibles in the listfragment, but when I scroll down and up, the changes become visible.</p>
  
  <p>ListFragment:</p>
  
  <pre><code> @Inject
  lateinit var viewModelFactory: ViewModelProvider.Factory
  val viewModel: ListViewModel by viewModels {
      viewModelFactory
  }
  
  override fun onCreateView(
      inflater: LayoutInflater, container: ViewGroup?,
      savedInstanceState: Bundle?
  ): View? {
      val bindings = ListFragmentBinding.inflate(inflater, container, false).apply {
          viewmodel = viewModel
      }
      bindings.lifecycleOwner = this
      adapter = ItemsAdapter()
      bindings.recyclerView.adapter = adapter
      viewModel.items.observe(
          viewLifecycleOwner,
          Observer { adapter.submitList(it)})
      return bindings.root
  }
  </code></pre>
  
  <p>ListViewModel:</p>
  
  <pre><code>var items: LiveData&lt;PagedList&lt;Item&gt;&gt; = repository.items
  </code></pre>
  
  <p>Repository:</p>
  
  <pre><code>val items&lt;PagedList&lt;Item&gt;&gt;
  get()=itemDao.getAllItemsPaged().toLiveData(pageSize=50)
  fun getItemFlow(id: String): Flow&lt;Item&gt; = itemDao.getItemFlow(id)
  suspend fun updateItem(item: Item) {
     itemDao.updateItem(item)
  }
  </code></pre>
  
  <p>ItemDao:</p>
  
  <pre><code> @Query("SELECT * FROM item")
  fun getAllItemsPaged(): DataSource.Factory&lt;Int,Item&gt;
  @Query("SELECT * FROM itemWHERE id=:id")
  fun getItemFlow(id:String):Flow&lt;Item&gt;
  @Update
  suspend fun updateItem(item:Item)
  </code></pre>
  
  <p>ItemFragment:</p>
  
  <pre><code>@Inject
  lateinit var viewModelFactory: ViewModelProvider.Factory
  val viewModel: ItemViewModel by viewModels {
      viewModelFactory
  }
  override fun onCreateView(
      inflater: LayoutInflater, container: ViewGroup?,
      savedInstanceState: Bundle?
  ): View? {
      viewModel.loadItem(args.itemId)
      val bindings = ItemFragmentBinding.inflate(inflater, container, false).apply {
          viewmodel = viewModel
          buttonSave.setOnClickListener{viewModel. viewModelScope.launch {
          viewModel.saveItem()
          findNavController().navigateUp()
      }}
  
      }
  
      bindings.lifecycleOwner = this
      return bindings.root
  }
  </code></pre>
  
  <p>ItemViewModel:</p>
  
  <pre><code>var item: LiveData&lt;Item&gt;? = null
  
  fun loadItem(id: String) {
      viewModelScope.launch {
          item = repository.getItemFlow(id).asLiveData()
      }
  }
  
  suspend fun saveItem() {
      item!!.value!!.someField = "hi"
      repository.updateItem(item!!.value!!)
  }
  </code></pre>