Revision 7125062f
b/snf-astakos-app/astakos/im/management/commands/astakos-quota.py | ||
---|---|---|
136 | 136 |
self.stdout.write(sep + '\n') |
137 | 137 |
|
138 | 138 |
for holder, holder_quotas in qh_quotas.iteritems(): |
139 |
h_initial = astakos_initial[holder]
|
|
140 |
email = info[holder]
|
|
139 |
h_initial = astakos_initial.get(holder)
|
|
140 |
email = info.get(holder, "")
|
|
141 | 141 |
for source, source_quotas in holder_quotas.iteritems(): |
142 |
s_initial = h_initial[source]
|
|
142 |
s_initial = h_initial.get(source) if h_initial else None
|
|
143 | 143 |
for resource, values in source_quotas.iteritems(): |
144 |
initial = str(s_initial[resource]) |
|
144 |
initial = s_initial.get(resource) if s_initial else None |
|
145 |
initial = str(initial) |
|
145 | 146 |
capacity = str(values['limit']) |
146 | 147 |
used = str(values['used']) |
147 | 148 |
|
Also available in: Unified diff