fixed serializer for newer android versions