Data map fixes
Make sure datamap is restored prior to returning counts or array values extracted from internal values
data() method returns keys and values as array, not just the values with auto incrmenting integer key.
Merge pull request #1079 from JeffPyeBrook/pr-data-map-auto-restore-bug-fix

Data map fixes