Loading django/contrib/gis/gdal/datasource.py +1 −1 Original line number Diff line number Diff line Loading @@ -86,7 +86,7 @@ class DataSource(GDALBase): else: raise OGRException('Invalid data source input type: %s' % type(ds_input)) if bool(ds): if ds: self.ptr = ds self.driver = Driver(ds_driver) else: Loading django/contrib/gis/gdal/geometries.py +1 −1 Original line number Diff line number Diff line Loading @@ -122,7 +122,7 @@ class OGRGeometry(GDALBase): self.ptr = g # Assigning the SpatialReference object to the geometry, if valid. if bool(srs): if srs: self.srs = srs # Setting the class depending upon the OGR Geometry Type Loading django/contrib/gis/gdal/prototypes/errcheck.py +1 −1 Original line number Diff line number Diff line Loading @@ -111,7 +111,7 @@ def check_pointer(result, func, cargs): "Makes sure the result pointer is valid." if isinstance(result, six.integer_types): result = c_void_p(result) if bool(result): if result: return result else: raise OGRException('Invalid pointer returned from "%s"' % func.__name__) Loading django/contrib/gis/geoip/prototypes.py +1 −1 Original line number Diff line number Diff line Loading @@ -50,7 +50,7 @@ GeoIPRecord_delete.restype = None # For retrieving records by name or address. def check_record(result, func, cargs): if bool(result): if result: # Checking the pointer to the C structure, if valid pull out elements # into a dicionary. rec = result.contents Loading django/contrib/gis/geos/geometry.py +1 −1 Original line number Diff line number Diff line Loading @@ -89,7 +89,7 @@ class GEOSGeometry(GEOSBase, ListMixin): # Invalid geometry type. raise TypeError('Improper geometry input type: %s' % str(type(geo_input))) if bool(g): if g: # Setting the pointer object with a valid pointer. self.ptr = g else: Loading Loading
django/contrib/gis/gdal/datasource.py +1 −1 Original line number Diff line number Diff line Loading @@ -86,7 +86,7 @@ class DataSource(GDALBase): else: raise OGRException('Invalid data source input type: %s' % type(ds_input)) if bool(ds): if ds: self.ptr = ds self.driver = Driver(ds_driver) else: Loading
django/contrib/gis/gdal/geometries.py +1 −1 Original line number Diff line number Diff line Loading @@ -122,7 +122,7 @@ class OGRGeometry(GDALBase): self.ptr = g # Assigning the SpatialReference object to the geometry, if valid. if bool(srs): if srs: self.srs = srs # Setting the class depending upon the OGR Geometry Type Loading
django/contrib/gis/gdal/prototypes/errcheck.py +1 −1 Original line number Diff line number Diff line Loading @@ -111,7 +111,7 @@ def check_pointer(result, func, cargs): "Makes sure the result pointer is valid." if isinstance(result, six.integer_types): result = c_void_p(result) if bool(result): if result: return result else: raise OGRException('Invalid pointer returned from "%s"' % func.__name__) Loading
django/contrib/gis/geoip/prototypes.py +1 −1 Original line number Diff line number Diff line Loading @@ -50,7 +50,7 @@ GeoIPRecord_delete.restype = None # For retrieving records by name or address. def check_record(result, func, cargs): if bool(result): if result: # Checking the pointer to the C structure, if valid pull out elements # into a dicionary. rec = result.contents Loading
django/contrib/gis/geos/geometry.py +1 −1 Original line number Diff line number Diff line Loading @@ -89,7 +89,7 @@ class GEOSGeometry(GEOSBase, ListMixin): # Invalid geometry type. raise TypeError('Improper geometry input type: %s' % str(type(geo_input))) if bool(g): if g: # Setting the pointer object with a valid pointer. self.ptr = g else: Loading