[1.6.x] Fixed #23282 -- Corrected inheritance and reverse relations example.

Thanks knowledgepoint-devs for the report and claudep for review.

Backport of 7006187064 from master