Fix for JAVA-794 - Fails to detect fields with dots for docs in arrays

I've fixed this. Tests included.