Skip to content

Commit

Permalink
Remove to_representation
Browse files Browse the repository at this point in the history
  • Loading branch information
sevfurneaux committed Feb 4, 2025
1 parent 89892dc commit 2f25af6
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions meinberlin/apps/kiezradar/serializers.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import json

from django.conf import settings
from django.utils.module_loading import import_string
from django.utils.translation import gettext as _
Expand Down Expand Up @@ -32,12 +30,6 @@ def validate(self, data):
)
return data

def to_representation(self, instance):
representation = super().to_representation(instance)
if isinstance(representation["point"], str):
representation["point"] = json.loads(representation["point"])
return representation


class SearchProfileSerializer(serializers.ModelSerializer):
"""Serializer for the SearchProfile model."""
Expand Down

0 comments on commit 2f25af6

Please sign in to comment.