Change Title of RelationManager

Is it correct that I need to use this method to change the title of a RelationManager?

public function getTitle(): string
{
    return __('strings.models.communications.plural');
}


This however doesn't work and I need to change it to:

public function getTitle(Model $ownerRecord, string $pageClass): string
{
    return __('strings.models.communications.plural');
}


Or is there something else I have to use?
Was this page helpful?