----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: http://reviewboard-openlmi.rhcloud.com/r/219/ -----------------------------------------------------------
Review request for OpenLMI Developers.
Repository: openlmi-storage
Description -------
Simplify error handling of FormatProvider.get_format_for_id and get_format_for_name.
With tuple (None, None) returned, following code can be used for error handling:
(device, fmt) = fmtprovider.get_format_for_name(...)
if not device: raise ...
With None, the unpacking would not be possible.
Also extend the documentation to explicitly state which device is returned.
Diffs -----
src/openlmi/storage/FormatProvider.py 611e9012ea9fbecae788cb1bfa1c635ff4f16c33
Diff: http://reviewboard-openlmi.rhcloud.com/r/219/diff/
Testing -------
Thanks,
Jan Safranek