Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CP Staging] fix: Categories - The subtitle under 'Members must categorize all expenses' contains 'undefined'. #44866

Merged
merged 4 commits into from
Jul 4, 2024
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ function WorkspaceCategoriesSettingsPage({policy, route}: WorkspaceCategoriesSet
<View style={styles.flexGrow1}>
<ToggleSettingOptionRow
title={translate('workspace.categories.requiresCategory')}
subtitle={toggleSubtitle}
subtitle={isConnectedToAccounting ? toggleSubtitle : undefined}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it would make more sense to make toggleSubtitle undefined than doing it here, can you update accordingly please

Copy link
Contributor Author

@Krishna2323 Krishna2323 Jul 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@allgandalf, can you pls check now. Sorry haven't pulled main branch yet, just a min.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

haha

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@allgandalf, pls check now.

switchAccessibilityLabel={toggleSubtitle}
isActive={policy?.requiresCategory ?? false}
onToggle={updateWorkspaceRequiresCategory}
Expand Down
Loading