Fixing object array indexing issue

Fixes issue of the library failing when we do array slicing on a netCDF4 variable containing objects.
Sometimes the library fails with: AttributeError: 'NoneType' object has no attribute 'shape' on that operation.
This should fix the error by returning () as the shape in instances where that will happen.