Skip to content

Commit

Permalink
Make applicationText nullable (#1276)
Browse files Browse the repository at this point in the history
  • Loading branch information
BentiGorlich committed Jan 7, 2025
1 parent f94783a commit 1e27955
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Entity/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ class User implements UserInterface, PasswordAuthenticatedUserInterface, Visibil
public string $type;

#[Column(type: 'text', nullable: true)]
public string $applicationText;
public ?string $applicationText;

#[Column(type: 'enumApplicationStatus', nullable: false, options: ['default' => EApplicationStatus::Approved->value])]
private string $applicationStatus;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ class InstanceSettingsRetrieveApiTest extends WebTestCase
'MBIN_SSO_ONLY_MODE',
'MBIN_SSO_SHOW_FIRST',
'MAX_IMAGE_BYTES',
'MBIN_NEW_USERS_NEED_APPROVAL',
];

public function testApiCannotRetrieveInstanceSettingsAnonymous(): void
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ class InstanceSettingsUpdateApiTest extends WebTestCase
'MBIN_SSO_ONLY_MODE',
'MBIN_SSO_SHOW_FIRST',
'MAX_IMAGE_BYTES',
'MBIN_NEW_USERS_NEED_APPROVAL',
];

public function testApiCannotUpdateInstanceSettingsAnonymous(): void
Expand Down Expand Up @@ -112,6 +113,7 @@ public function testApiCanUpdateInstanceSettings(): void
'MBIN_SSO_ONLY_MODE' => false,
'MBIN_SSO_SHOW_FIRST' => false,
'MAX_IMAGE_BYTES' => 10000,
'MBIN_NEW_USERS_NEED_APPROVAL' => false,
];

$this->client->jsonRequest('PUT', '/api/instance/settings', $settings, server: ['HTTP_AUTHORIZATION' => $token]);
Expand Down Expand Up @@ -152,6 +154,7 @@ public function testApiCanUpdateInstanceSettings(): void
'MBIN_SSO_ONLY_MODE' => true,
'MBIN_SSO_SHOW_FIRST' => true,
'MAX_IMAGE_BYTES' => 30000,
'MBIN_NEW_USERS_NEED_APPROVAL' => false,
];

$this->client->jsonRequest('PUT', '/api/instance/settings', $settings, server: ['HTTP_AUTHORIZATION' => $token]);
Expand Down

0 comments on commit 1e27955

Please sign in to comment.