public function setRepository(RepositoryInterface $repository) { $this->repository = $repository; $this->translator->setRepository($repository); return $this; }