dont turn data into string, fixes #2797

This commit is contained in:
j 2015-05-28 13:10:39 +02:00
parent 5cc23093ef
commit adb831ce70

View file

@ -177,9 +177,7 @@ def removePlace(request, data):
returns {}
see: addPlace, editPlace, findPlaces
'''
if isinstance(data, dict):
data = data['id']
place = get_object_or_404_json(models.Place, pk=ox.fromAZ(data))
place = get_object_or_404_json(models.Place, pk=ox.fromAZ(data['id']))
if place.editable(request.user):
add_changelog(request, data)
place.delete()