File tree Expand file tree Collapse file tree 2 files changed +2
-12
lines changed
Expand file tree Collapse file tree 2 files changed +2
-12
lines changed Original file line number Diff line number Diff line change 1+ Fixed the method for displaying the representation of ``MasterModel`` objects.
Original file line number Diff line number Diff line change @@ -197,18 +197,7 @@ def master(self):
197197
198198 def __str__ (self ):
199199 # similar to Model's __str__, but type-aware
200- cast = self .cast ()
201- if cast is self :
202- return super ().__str__ ()
203-
204- try :
205- return "<{} (pulp_type={}): {}>" .format (
206- self ._meta .object_name , cast .pulp_type , cast .name
207- )
208- except AttributeError :
209- return "<{} (pulp_type={}): pk={}>" .format (
210- self ._meta .object_name , cast .pulp_type , cast .pk
211- )
200+ return "<{} (pulp_type={}): pk={}>" .format (self ._meta .object_name , self .pulp_type , self .pk )
212201
213202
214203# Add properties to model _meta info to support master/detail models
You can’t perform that action at this time.
0 commit comments