Skip to content

Commit 5c37057

Browse files
committed
🔧 Fix SharedViewModel: Add required coroutineScope
Used rememberCoroutineScope() to provide the required scope. Fixes: No value passed for parameter 'coroutineScope'
1 parent a8dc8f8 commit 5c37057

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎androidApp/src/main/kotlin/com/qrshield/android/ui/QRShieldApp.kt‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ import com.qrshield.ui.UiState
1616
*/
1717
@OptIn(ExperimentalMaterial3Api::class)
1818
@Composable
19-
fun QRShieldApp(
20-
viewModel: SharedViewModel = remember { SharedViewModel() }
21-
) {
19+
fun QRShieldApp() {
20+
val coroutineScope = rememberCoroutineScope()
21+
val viewModel = remember { SharedViewModel(coroutineScope = coroutineScope) }
2222
val uiState by viewModel.uiState.collectAsState()
2323

2424
Scaffold(

0 commit comments

Comments
 (0)