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

Do not store recently used if 'recent' category is excluded. #83

Merged
merged 3 commits into from May 29, 2017
Merged

Do not store recently used if 'recent' category is excluded. #83

merged 3 commits into from May 29, 2017

Conversation

samkelleher
Copy link

If the recent category is excluded, this PR ensures that the Picker respects this and does not write to local storage anyway.

Previously, recent usage would be written to storage even if the recent category was ignored.

@@ -87,6 +89,7 @@ export default class Picker extends React.Component {
let includeRecent = props.include == undefined ? true : props.include.indexOf('recent') > -1
let excludeRecent = props.exclude == undefined ? false : props.exclude.indexOf('recent') > -1
if (includeRecent && !excludeRecent) {
this.hideRecent = true
Copy link
Member

Choose a reason for hiding this comment

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

I think this should be the other way around, right?

@samkelleher
Copy link
Author

Thanks for checking my mistake @EtienneLem - all good now. 😊

@EtienneLem EtienneLem merged commit 5abb2b6 into missive:master May 29, 2017
@EtienneLem
Copy link
Member

Sweet, thanks! 🤘

@samkelleher samkelleher deleted the exclude-recent branch May 29, 2017 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants