This repository was archived by the owner on Apr 17, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 24
Realnames #96
Open
LucasSloan
wants to merge
10
commits into
bellroy:master
Choose a base branch
from
LucasSloan:realnames
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Realnames #96
Changes from 1 commit
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
ed22f70
Merge branch 'master' of https://github.com/tricycle/lesswrong
LucasSloan 3a61c26
Merge branch 'master' of https://github.com/tricycle/lesswrong
LucasSloan 300ada3
Merge branch 'master' of https://github.com/tricycle/lesswrong
LucasSloan d3078f7
New feature - real names. Add a real name in preferences and user fa…
LucasSloan fec33b9
New feature - real names. Add a real name in preferences and user fa…
LucasSloan 1a2f01c
Merge branch 'realnames' of https://github.com/PotatoDumplings/lesswr…
LucasSloan bdba277
Allow real names to use full Unicode character set.
LucasSloan 2dff67e
Removed unnecessary Account commit.
e3dea7f
Move realname error checking into a multiple boolean, not multiple if…
LucasSloan 30b9399
Clear the realname field to remove a realname.
LucasSloan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Move realname error checking into a multiple boolean, not multiple if…
… expression. Indicate that a real name is optional on the preferences screen.
- Loading branch information
commit e3dea7f3e6477a4ad8249bd1cec3537ed4f9a6f1
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -588,12 +588,8 @@ def POST_update(self, res, email, curpass, realname, password, newpass, verpass) | |
| res._update('curpass', value='') | ||
| return | ||
|
|
||
| if res._chk_error(errors.BAD_REALNAME_CHARS): | ||
| if res._chk_error(errors.BAD_REALNAME_CHARS) or res._chk_error(errors.BAD_REALNAME_SHORT) or res._chk_error(errors.BAD_REALNAME_LONG): | ||
| res._focus('real_name') | ||
| elif res._chk_error(errors.BAD_REALNAME_SHORT): | ||
| res._focus('real_name') | ||
| elif res._chk_error(errors.BAD_REALNAME_LONG): | ||
| res._focus('real_name') | ||
| if realname and realname == c.user.real_name: | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think the best way to deal with this is to pre-fill the form with the user's current realname, and if they blank it out then delete it from their profile. If it's unchanged then we can infer that the form is being used for something else (password change etc.). |
||
| c.user.real_name = None | ||
| c.user._commit() | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule manual_test_script
updated
from a49ad9 to c2d154
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems wrong to me. I think you should remove minimum length limits on real names and make it so that an empty string is interpreted as a request to delete.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've tried that but it doesn't really work in this case - the update password/email/realname form handles 3 different actions - entering nothing should result in nothing happening. I suspect that people will want to remove their real name rarely enough to make the bizarre syntax acceptable, unless you have a better suggestion?