Skip to content

Commit bbf2132

Browse files
committed
fix: add initial state for translation provider
Signed-off-by: Jana Peper <jana.peper@nextcloud.com>
1 parent 29679c2 commit bbf2132

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

lib/Service/InitialStateProvider.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ public function provideState(): void {
5656
);
5757

5858
$taskTypes = $this->taskProcessingManager->getAvailableTaskTypes();
59+
60+
$this->initialState->provideInitialState(
61+
'translation_available',
62+
isset($taskTypes['core:text2text:translate']),
63+
);
64+
5965
$fromLanguages = $taskTypes['core:text2text:translate']['inputShapeEnumValues']['origin_language'] ?? [];
6066
$toLanguages = $taskTypes['core:text2text:translate']['inputShapeEnumValues']['target_language'] ?? [];
6167

0 commit comments

Comments
 (0)