La classe XiboWidgetNotificationView est introuvable#0

Hello, I encountered the following error:

La classe XiboWidgetNotificationView est introuvable#0 /var/www/xibo2/lib/Factory/ModuleFactory.php(239): Xibo\Service\ModuleService->getByClass('XiboWidgetNotif...', Object(Xibo\Factory\ModuleFactory), Object(Xibo\Factory\MediaFactory), Object(Xibo\Factory\DataSetFactory), Object(Xibo\Factory\DataSetColumnFactory), Object(Xibo\Factory\TransitionFactory), Object(Xibo\Factory\DisplayFactory), Object(Xibo\Factory\CommandFactory), Object(Xibo\Factory\ScheduleFactory), Object(Xibo\Factory\PermissionFactory), Object(Xibo\Factory\UserGroupFactory), Object(Xibo\Factory\PlaylistFactory)) #1 /var/www/xibo2/lib/Controller/Layout.php(209): Xibo\Factory\ModuleFactory->createForInstall('XiboWidgetNotif...') #2 [internal function]: Xibo\Controller\Layout->Xibo\Controller\{closure}(Object(Xibo\Entity\Module)) #3 /var/www/xibo2/lib/Controller/Layo…..

To temporarily solve this problem, I implemented an if in the code of ModuleFactory.php, but this is not good practice, can you tell me how to modify it correctly.
This is what I did:

public function createForInstall($className)
   {
if($className === 'XiboWidgetNotificationView'){
        $className = 'Xibo\Widget\NotificationView';

        }
        // Create a module
        return $this->moduleService->getByClass(
            $className,
            $this,
            $this->mediaFactory,
            $this->dataSetFactory,
            $this->dataSetColumnFactory,
            $this->transitionFactory,
            $this->displayFactory,
            $this->commandFactory,
            $this->scheduleFactory,
            $this->permissionFactory,
            $this->userGroupFactory,
            $this->playlistFactory
        );
    }

Thanks in advance.