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

added values 'on' and 'off' for 'trusted' option #1318

Merged

Conversation

@ChaosKid42
Copy link
Contributor

commented Nov 10, 2018

This PR introduces values on and off for the trusted option. This can be used to hide the "This is a trusted device" checkbox from the user.

@ChaosKid42 ChaosKid42 force-pushed the ChaosKid42:option_to_remove_trusted_checkbox branch 3 times, most recently from 9e6915a to 0e453dd Nov 10, 2018

data-title="Trusted device?"
data-content="{{{o.__('To improve performance, we cache your data in this browser. Uncheck this box if this is a public computer or if you want your data to be deleted when you log out. It\'s important that you explicitly log out, otherwise not all cached data might be deleted. Please note, when using an untrusted device, OMEMO encryption is NOT available.')}}}"></i>
</div>
{[ if (o.trusted !== 'on' && o.trusted !== 'off') { ]}

This comment has been minimized.

Copy link
@jcbrand

jcbrand Nov 10, 2018

Member

It would be easier to read and to understand what's going on if you pass in a descriptive variable name.

For example, instead of passing in 'trusted': _converse.trusted when calling the template, you pass in 'show_trust_checkbox': o.trusted !== 'on' && o.trusted !== 'off'

This comment has been minimized.

Copy link
@ChaosKid42

ChaosKid42 Nov 10, 2018

Author Contributor

That's true. Updated the PR accordingly.

@ChaosKid42 ChaosKid42 force-pushed the ChaosKid42:option_to_remove_trusted_checkbox branch 4 times, most recently from cf20dce to 174ef41 Nov 10, 2018

@jcbrand jcbrand force-pushed the conversejs:master branch from 0bffcd6 to d2b0fa7 Nov 12, 2018

@ChaosKid42 ChaosKid42 force-pushed the ChaosKid42:option_to_remove_trusted_checkbox branch from 174ef41 to 09fad3d Nov 12, 2018

@jcbrand jcbrand merged commit 4b7d18f into conversejs:master Nov 13, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@ChaosKid42 ChaosKid42 deleted the ChaosKid42:option_to_remove_trusted_checkbox branch Nov 13, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.