- changed it to using json serializer