Page MenuHomePhorge

Normalize objectclass attribute values (#5423)
ClosedPublic

Authored by machniak on May 11 2016, 3:00 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Oct 6, 11:24 AM
Unknown Object (File)
Sat, Oct 5, 2:38 PM
Unknown Object (File)
Wed, Oct 2, 7:52 PM
Unknown Object (File)
Wed, Oct 2, 10:25 AM
Unknown Object (File)
Thu, Sep 19, 7:41 PM
Unknown Object (File)
Thu, Sep 19, 7:34 PM
Unknown Object (File)
Thu, Sep 19, 7:33 PM
Unknown Object (File)
Thu, Sep 19, 7:30 PM

Details

Diff Detail

Repository
rP pykolab
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

machniak retitled this revision from to Normalize objectclass attribute values (#5423).
machniak updated this object.
machniak edited the test plan for this revision. (Show Details)
machniak added a reviewer: PyKolab Developers.

We already added this code snipet to our test system and run a huge "sync --resync" which seams to add users which where not added earlier.
So I'd like to say we tested it intensively and feel real good with this patch. It's working as intended.

vanmeeuwen added a reviewer: vanmeeuwen.
vanmeeuwen subscribed.
vanmeeuwen added inline comments.
pykolab/utils.py
398

This isn't generally our coding style -- difficult to read.

This can just be:

if not result.has_key('objectclass'):
  result['objectclass'] = []

if result['objectclass'] is None:
  result['objectclass'] = []

if not isinstance(result['objectclass'], list):
  result['objectclass'] = [result['objectclass']]

result['objectclass'] = [x.lower() for x in result['objectclass']]
This revision now requires changes to proceed.May 13 2016, 10:56 AM
machniak edited edge metadata.

Fix code style

vanmeeuwen edited edge metadata.
This revision is now accepted and ready to land.May 18 2016, 9:37 AM
This revision was automatically updated to reflect the committed changes.