Skip to content

Commit

Permalink
Address PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
CrisBarreiro committed Nov 28, 2024
1 parent 301c7fc commit 29e8164
Showing 1 changed file with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,12 @@ class PrivacyDashboardHybridActivity : DuckDuckGoActivity() {
onBrokenSiteClicked = { viewModel.onReportBrokenSiteSelected() },
onClose = { this@PrivacyDashboardHybridActivity.finish() },
onSubmitBrokenSiteReport = { payload ->
val reportFlow = when (params) {
val reportFlow = when (val params = params) {
is PrivacyDashboardPrimaryScreen, null -> ReportFlow.DASHBOARD
is BrokenSiteForm -> {
if ((params as BrokenSiteForm).reportFlow == BrokenSiteForm.BrokenSiteFormReportFlow.MENU) {
ReportFlow.MENU
} else {
ReportFlow.PROMPT
when (params.reportFlow) {
BrokenSiteForm.BrokenSiteFormReportFlow.MENU -> ReportFlow.MENU
BrokenSiteForm.BrokenSiteFormReportFlow.PROMPT -> ReportFlow.PROMPT
}
}
}
Expand Down

0 comments on commit 29e8164

Please sign in to comment.