X-Git-Url: https://plomlompom.com/repos/%7B%7B%20web_path%20%7D%7D/decks/%7B%7Bdeck_id%7D%7D/cards/%7B%7Bcard_id%7D%7D/form?a=blobdiff_plain;f=calories.py;fp=calories.py;h=28b1a16e0e99dfea186d6ff91f7dd8c006d1dad0;hb=5a6e56223e59fb628f88070957b39a42d3b7c945;hp=4352567aafa9e8bcdd9e31b2d4b4dcc0b52d43e3;hpb=389620d37f697f869ed051071db5dead95a152fe;p=misc diff --git a/calories.py b/calories.py index 4352567..28b1a16 100644 --- a/calories.py +++ b/calories.py @@ -251,8 +251,7 @@ class ConsumptionsHandler(PlomHandler): to_delete += [target] i = 0 if 'eatable_uuid' in postvars.keys(): - for uuid_encoded in postvars['eatable_uuid']: - uuid = uuid_encoded + for uuid in postvars['eatable_uuid']: if uuid not in to_delete: e = Eatable(decode("title", i, False), decode("cals", i), decode("sugar_g", i), decode("standard_g", i), decode("comments", i, False)) db.add_eatable(uuid, e)