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

Pass showVerifiedContacts to ContactList component #580

Merged
merged 1 commit into from
Jan 11, 2019
Merged
Show file tree
Hide file tree
Changes from all 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
Pass showVerifiedContacts to ContactList component
  • Loading branch information
ralphtheninja committed Jan 11, 2019
commit 7e7e7589d2f094fcfbed196c0de1c0910d64615f
2 changes: 1 addition & 1 deletion src/renderer/components/ContactList.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class ContactList extends React.Component {
}

_getContacts () {
const listFlags = this.state.showVerifiedContacts ? C.DC_GCL_VERIFIED_ONLY : 0
const listFlags = this.props.showVerifiedContacts ? C.DC_GCL_VERIFIED_ONLY : 0
const contacts = ipcRenderer.sendSync(
'dispatchSync', 'getContacts', listFlags, this.state.queryStr
)
Expand Down
5 changes: 4 additions & 1 deletion src/renderer/components/GroupBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,8 @@ class GroupBase extends React.Component {
render () {
const {
showQrVerifyCodeButton,
showQrInviteCodeButton
showQrInviteCodeButton,
showVerifiedContacts
} = this.state
const tx = window.translate
const image = this.state.image || '../images/group_default.png'
Expand Down Expand Up @@ -160,6 +161,7 @@ class GroupBase extends React.Component {
return { color: !this.contactInGroupStateChanged(contact.id) ? 'green' : 'yellow' }
}}
onContactClick={this.toggleContact.bind(this)}
showVerifiedContacts={showVerifiedContacts}
/>
</td>
<td>
Expand All @@ -169,6 +171,7 @@ class GroupBase extends React.Component {
return { color: this.contactInGroupStateChanged(contact.id) ? 'red' : '' }
}}
onContactClick={this.toggleContact.bind(this)}
showVerifiedContacts={showVerifiedContacts}
/>
</td>
</tr>
Expand Down