Skip to content

Commit 5f4a67e

Browse files
committed
chore: do not set a default for longtext db fields
Signed-off-by: Anupam Kumar <kyteinsky@gmail.com>
1 parent f76d909 commit 5f4a67e

File tree

4 files changed

+2
-4
lines changed

4 files changed

+2
-4
lines changed

lib/Controller/ChattyLLMController.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,8 @@ public function newSession(int $timestamp, ?string $title = null): JSONResponse
140140
$session->setUserId($this->userId);
141141
$session->setTitle($title);
142142
$session->setTimestamp($timestamp);
143+
$session->setAgencyConversationToken(null);
144+
$session->setAgencyPendingActions(null);
143145
$this->sessionMapper->insert($session);
144146

145147
$systemMsg = new Message();

lib/Migration/Version020200Date20241218145833.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,12 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt
3232
if (!$table->hasColumn('conversation_token')) {
3333
$table->addColumn('agency_conversation_token', Types::TEXT, [
3434
'notnull' => false,
35-
'default' => null,
3635
]);
3736
$schemaChanged = true;
3837
}
3938
if (!$table->hasColumn('agency_pending_actions')) {
4039
$table->addColumn('agency_pending_actions', Types::TEXT, [
4140
'notnull' => false,
42-
'default' => null,
4341
]);
4442
$schemaChanged = true;
4543
}

lib/Migration/Version020500Date20250425125359.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt
3232
if (!$table->hasColumn('sources')) {
3333
$table->addColumn('sources', Types::TEXT, [
3434
'notnull' => true,
35-
'default' => '[]',
3635
]);
3736
$schemaChanged = true;
3837
}

lib/Migration/Version020600Date20250704145036.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt
3232
if (!$table->hasColumn('attachments')) {
3333
$table->addColumn('attachments', Types::TEXT, [
3434
'notnull' => true,
35-
'default' => '[]',
3635
]);
3736
$schemaChanged = true;
3837
}

0 commit comments

Comments
 (0)