Skip to content

Commit

Permalink
code review updates
Browse files Browse the repository at this point in the history
  • Loading branch information
TMisiukiewicz committed Dec 15, 2023
1 parent 770a525 commit d6beb16
Show file tree
Hide file tree
Showing 8 changed files with 3 additions and 17 deletions.
1 change: 0 additions & 1 deletion src/CONST.ts
Original file line number Diff line number Diff line change
Expand Up @@ -703,7 +703,6 @@ const CONST = {
TOOLTIP_SENSE: 1000,
TRIE_INITIALIZATION: 'trie_initialization',
COMMENT_LENGTH_DEBOUNCE_TIME: 500,
SEARCH_FOR_REPORTS_DEBOUNCE_TIME: 300,
SEARCH_OPTION_LIST_DEBOUNCE_TIME: 200,
},
PRIORITY_MODE: {
Expand Down
1 change: 0 additions & 1 deletion src/components/MoneyRequestConfirmationList.js
Original file line number Diff line number Diff line change
Expand Up @@ -565,7 +565,6 @@ function MoneyRequestConfirmationList(props) {
return (
<OptionsSelector
sections={optionSelectorSections}
value=""
onSelectRow={canModifyParticipants ? selectParticipant : navigateToReportOrUserDetail}
onAddToSelection={selectParticipant}
onConfirmSelection={confirm}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -565,7 +565,6 @@ function MoneyTemporaryForRefactorRequestConfirmationList({
return (
<OptionsSelector
sections={optionSelectorSections}
value=""
onSelectRow={userCanModifyParticipants.current ? selectParticipant : navigateToReportOrUserDetail}
onAddToSelection={selectParticipant}
onConfirmSelection={confirm}
Expand Down
9 changes: 1 addition & 8 deletions src/pages/SearchPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,14 +155,7 @@ class SearchPage extends Component {
}

if (option.reportID) {
this.setState(
{
searchValue: '',
},
() => {
Navigation.dismissModal(option.reportID);
},
);
Navigation.dismissModal(option.reportID);
} else {
Report.navigateToAndOpenReport([option.login]);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,6 @@ function MoneyTemporaryForRefactorRequestParticipantsSelector({
onAddToSelection={addParticipantToSelection}
sections={sections}
selectedOptions={participants}
value={searchTerm}
onSelectRow={addSingleParticipant}
onChangeText={setSearchTermAndSearchInServer}
ref={forwardedRef}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,8 @@ function MoneyRequestParticipantsSelector({
/>
</View>
),
[handleConfirmSelection, shouldShowSplitBillErrorMessage, styles.mb2, styles.ph1, translate],
// eslint-disable-next-line react-hooks/exhaustive-deps
[handleConfirmSelection, shouldShowSplitBillErrorMessage, translate],
);

return (
Expand Down
2 changes: 0 additions & 2 deletions src/pages/tasks/TaskAssigneeSelectorModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,6 @@ function TaskAssigneeSelectorModal(props) {
// Check to see if we're creating a new task
// If there's no route params, we're creating a new task
if (!props.route.params && option.accountID) {
// Clear out the state value, set the assignee and navigate back to the NewTaskPage
setSearchValue('');
Task.setAssigneeValue(option.login, option.accountID, props.task.shareDestination, OptionsListUtils.isCurrentUser(option));
return Navigation.goBack(ROUTES.NEW_TASK);
}
Expand Down
2 changes: 0 additions & 2 deletions src/pages/tasks/TaskShareDestinationSelectorModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,6 @@ function TaskShareDestinationSelectorModal(props) {
}

if (option.reportID) {
// Clear out the state value, set the assignee and navigate back to the NewTaskPage
setSearchValue('');
Task.setShareDestinationValue(option.reportID);
Navigation.goBack(ROUTES.NEW_TASK);
}
Expand Down

0 comments on commit d6beb16

Please sign in to comment.