diff --git a/typo3/sysext/scheduler/Classes/Task/AbstractTask.php b/typo3/sysext/scheduler/Classes/Task/AbstractTask.php
index 53743fd0d8b67b14429f138779444601ded835ce..d7e3bd3d950c19b75cc37b1bf5e2372a5343fb23 100644
--- a/typo3/sysext/scheduler/Classes/Task/AbstractTask.php
+++ b/typo3/sysext/scheduler/Classes/Task/AbstractTask.php
@@ -471,7 +471,7 @@ abstract class AbstractTask implements LoggerAwareInterface
      * @param int $executionID Id of the execution to remove.
      * @param \Throwable $e An exception to signal a failed execution
      */
-    public function unmarkExecution($executionID, \Throwable $e = null)
+    public function unmarkExecution($executionID, ?\Throwable $e = null)
     {
         // Get the executions for the task
         $queryBuilder = GeneralUtility::makeInstance(ConnectionPool::class)
diff --git a/typo3/sysext/scheduler/Classes/Task/FileStorageExtractionAdditionalFieldProvider.php b/typo3/sysext/scheduler/Classes/Task/FileStorageExtractionAdditionalFieldProvider.php
index fe66c2099210b4e9b3b2a64610e14b8e6053f3bb..6e48df6ea5b7746bf73c66d32650032972306e30 100644
--- a/typo3/sysext/scheduler/Classes/Task/FileStorageExtractionAdditionalFieldProvider.php
+++ b/typo3/sysext/scheduler/Classes/Task/FileStorageExtractionAdditionalFieldProvider.php
@@ -57,7 +57,7 @@ class FileStorageExtractionAdditionalFieldProvider implements AdditionalFieldPro
      * @param FileStorageExtractionTask|null $task When editing, reference to the current task object. NULL when adding.
      * @return array Array containing all the information pertaining to the additional fields
      */
-    protected function getAllStoragesField(FileStorageExtractionTask $task = null)
+    protected function getAllStoragesField(?FileStorageExtractionTask $task = null)
     {
         /** @var ResourceStorage[] $storages */
         $storages = GeneralUtility::makeInstance(StorageRepository::class)->findAll();
@@ -89,7 +89,7 @@ class FileStorageExtractionAdditionalFieldProvider implements AdditionalFieldPro
      * @param FileStorageExtractionTask|null $task When editing, reference to the current task object. NULL when adding.
      * @return array Array containing all the information pertaining to the additional fields
      */
-    protected function getFileCountField(FileStorageExtractionTask $task = null)
+    protected function getFileCountField(?FileStorageExtractionTask $task = null)
     {
         $fieldName = 'tx_scheduler[scheduler_fileStorageIndexing_fileCount]';
         $fieldId = 'scheduler_fileStorageIndexing_fileCount';
@@ -111,7 +111,7 @@ class FileStorageExtractionAdditionalFieldProvider implements AdditionalFieldPro
      * @param FileStorageExtractionTask|null $task When editing, reference to the current task object. NULL when adding.
      * @return array Array containing all the information pertaining to the additional fields
      */
-    protected function getRegisteredExtractorsField(FileStorageExtractionTask $task = null)
+    protected function getRegisteredExtractorsField(?FileStorageExtractionTask $task = null)
     {
         $extractors = GeneralUtility::makeInstance(ExtractorRegistry::class)->getExtractors();