AttributeError chaining bug #1944 fix
This commit is contained in:
		
							parent
							
								
									8639bf7554
								
							
						
					
					
						commit
						65be1231b1
					
				|  | @ -205,11 +205,10 @@ class PyobjContext(object): | ||||||
| class PyobjMixin(PyobjContext): | class PyobjMixin(PyobjContext): | ||||||
|     def obj(): |     def obj(): | ||||||
|         def fget(self): |         def fget(self): | ||||||
|             try: |             obj = getattr(self, '_obj', None) | ||||||
|                 return self._obj |             if obj is None: | ||||||
|             except AttributeError: |  | ||||||
|                 self._obj = obj = self._getobj() |                 self._obj = obj = self._getobj() | ||||||
|                 return obj |             return obj | ||||||
|         def fset(self, value): |         def fset(self, value): | ||||||
|             self._obj = value |             self._obj = value | ||||||
|         return property(fget, fset, None, "underlying python object") |         return property(fget, fset, None, "underlying python object") | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue