Skip to content
This repository has been archived by the owner on Sep 29, 2023. It is now read-only.

Check for existence of password in skeleton before modifying it in modules.user.User.addSkel() #24

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

phorward
Copy link
Member

@phorward phorward commented Nov 8, 2017

There are cases (e.g. with different login methods) that a userSkel has an unset password bone because it is not necessary or wanted.

There are cases (e.g. with different login methods) that a userSkel has an unset password bone because it is not necessary or wanted.
skel.password.required = True
skel.password.visible = True
skel.password.readOnly = False
if "password" in skel:
Copy link
Contributor

Choose a reason for hiding this comment

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

How can the password bone not be in that skel? It's calling the underlying prototypes/list.py:addSkel, which in turn calls self._resolveSkelCls. None of these can / should mess with the skeleton.

Copy link
Member Author

Choose a reason for hiding this comment

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

This happens in a case where my project does not use the Username-Password-method, but Google user and another login method.

Copy link
Member Author

Choose a reason for hiding this comment

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

This issue is now over one year old. Can you please apply it? Under several reasons, a password bone is not available in different projects.

Copy link
Contributor

Choose a reason for hiding this comment

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

Any inputs from others?
I don't mind if we merge this as it won't break anything, but in my opinion you are doing something wrong if you can trigger this. My preferred method would be setting the bone to visible=False and readOnly=True instead of removing it from the predefined skeleton. These bones are there for a reason, you remove parententry from hierarchySkels things will fall apart similarly.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants