diff --git a/opendrift/readers/reader_schism_native.py b/opendrift/readers/reader_schism_native.py index d1da14f6d..292c7ec19 100755 --- a/opendrift/readers/reader_schism_native.py +++ b/opendrift/readers/reader_schism_native.py @@ -212,8 +212,8 @@ def __init__(self, filename=None, name=None, proj4=None, use_3d = None): self.numy = var.shape[0] if standard_name == 'depth' or axis == 'Z': var_data = var.values - if 'positive' not in var.ncattrs() or \ - var.__dict__['positive'] == 'up': + if 'positive' not in var.attrs or \ + var.attrs['positive'] == 'up': self.z = var_data else: self.z = -var_data