fix for bug in serializer