Skip to content

Commit 77b34cb

Browse files
committed
erase query when searching
1 parent 98ecc07 commit 77b34cb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

source/views/sis/course-search/search.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ class CourseSearchView extends React.Component<Props, State> {
7575
// if no terms are cached, and the user didn't push the button,
7676
// then don't download anything.
7777
this.setState(() => ({mode: 'pending'}))
78-
return;
78+
return
7979
}
8080

8181
this.setState(() => ({mode: 'loading'}))
@@ -102,10 +102,10 @@ class CourseSearchView extends React.Component<Props, State> {
102102
}
103103

104104
handleSearchSubmit = () => {
105-
this.setState(() => ({isSearchbarActive: false}))
106105
this.props.navigation.push('CourseSearchResultsView', {
107106
initialQuery: this.state.typedQuery,
108107
})
108+
this.setState(() => ({isSearchbarActive: false, typedQuery: ''}))
109109
}
110110

111111
handleSearchCancel = () => {

0 commit comments

Comments
 (0)