Code review comment for lp:~jakedahn/nova/os-quotas

Revision history for this message
Devin Carlen (devcamcar) wrote :

Looks good with some style nits:

27 +from nova.auth import manager as auth_manager
28 +from nova.api.openstack import extensions

Can you arrange these alphabetically?

36 + return {'quota_set': {
37 + 'id': str(project_id),

'id' should align with 'quota_set'

38 + 'metadata_items': quota_set['metadata_items'],
39 + 'injected_file_content_bytes':
...
46 + 'injected_files': quota_set['injected_files'],
47 + 'cores': quota_set['cores'],

Closing braces are generally on previous line.

48 + }}

57 + context = req.environ['nova.context']
58 + user = req.environ.get('user')

Why use .get('user')? What does it mean to request projects with user=None, which is what this check implies you can do?

review: Needs Fixing

« Back to merge proposal