-
-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #536 from plone/remove-portal_properties
Removed portal_properties from documentation and tests.
- Loading branch information
Showing
5 changed files
with
22 additions
and
49 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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 |
---|---|---|
|
@@ -26,12 +26,7 @@ If your portal is configured to use emails as usernames, you just need to pass i | |
% invisible-code-block: python | ||
% | ||
% from plone import api | ||
% from plone.api.exc import InvalidParameterError | ||
% try: | ||
% api.portal.set_registry_record('plone.use_email_as_login', True) | ||
% except InvalidParameterError: | ||
% portal = api.portal.get() | ||
% portal.portal_properties.site_properties.use_email_as_login = True | ||
% api.portal.set_registry_record('plone.use_email_as_login', True) | ||
|
||
```python | ||
from plone import api | ||
|
@@ -47,11 +42,7 @@ Otherwise, you also need to pass in the username of the new user. | |
|
||
% invisible-code-block: python | ||
% | ||
% try: | ||
% api.portal.set_registry_record('plone.use_email_as_login', False) | ||
% except InvalidParameterError: | ||
% portal = api.portal.get() | ||
% portal.portal_properties.site_properties.use_email_as_login = False | ||
% api.portal.set_registry_record('plone.use_email_as_login', False) | ||
|
||
```python | ||
user = api.user.create(email='[email protected]', username='jane') | ||
|
This file contains 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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Removed `portal_properties` from documentation and tests. | ||
[maurits] |
This file contains 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
This file contains 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