Make getattr play better with recursion