null is not an error
it works now 🎉
	
	
This commit is contained in:
		
					parent
					
						
							
								439b8aa4f0
							
						
					
				
			
			
				commit
				
					
						3a8ae37c09
					
				
			
		
					 1 changed files with 2 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -52,7 +52,8 @@ class DashboardActivity : ComponentActivity() {
 | 
			
		|||
        lifecycleScope.launch {
 | 
			
		||||
            repeatOnLifecycle(Lifecycle.State.STARTED) {
 | 
			
		||||
                dashboardViewModel.refreshError.collect {
 | 
			
		||||
                    Toast.makeText(baseContext, it, Toast.LENGTH_SHORT).show()
 | 
			
		||||
                    if (it != null)
 | 
			
		||||
                        Toast.makeText(baseContext, it, Toast.LENGTH_SHORT).show()
 | 
			
		||||
                } // TODO any better way?
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue