google-developer-training / basic-android-kotlin-compose-training-inventory-app

Apache License 2.0
77 stars 84 forks source link

Read and update data using Room #112

Open nic3point0 opened 6 months ago

nic3point0 commented 6 months ago

URL of codelab: https://developer.android.com/codelabs/basic-android-kotlin-compose-update-data-room#7

When adding the function reduceQuantityByOne() in step: 3

The instructions say to create a variable this way val currentItem = uiState.value.toItem(). The correct way is val currentItem = uiState.value.itemDetails.toItem(). The itemDetails property is missing.