mirror of
https://github.com/immich-app/immich.git
synced 2025-06-03 19:19:23 +02:00
fix: test
This commit is contained in:
parent
3b88e3aeef
commit
0890d018a7
5 changed files with 6 additions and 7 deletions
docs/docs/install
server/src
web/src/lib/components/shared-components/settings
|
@ -123,7 +123,6 @@ The default configuration looks like this:
|
|||
"buttonText": "Login with OAuth",
|
||||
"clientId": "",
|
||||
"clientSecret": "",
|
||||
"defaultStorageQuota": 0,
|
||||
"enabled": false,
|
||||
"issuerUrl": "",
|
||||
"mobileOverrideEnabled": false,
|
||||
|
|
|
@ -112,7 +112,6 @@ const updatedConfig = Object.freeze<SystemConfig>({
|
|||
buttonText: 'Login with OAuth',
|
||||
clientId: '',
|
||||
clientSecret: '',
|
||||
defaultStorageQuota: 0,
|
||||
enabled: false,
|
||||
issuerUrl: '',
|
||||
mobileOverrideEnabled: false,
|
||||
|
|
|
@ -17,10 +17,6 @@ describe('getKeysDeep', () => {
|
|||
).toEqual(['foo', 'flag', 'count', 'date']);
|
||||
});
|
||||
|
||||
it('should skip undefined properties', () => {
|
||||
expect(getKeysDeep({ foo: 'bar', hello: undefined })).toEqual(['foo']);
|
||||
});
|
||||
|
||||
it('should skip array indices', () => {
|
||||
expect(getKeysDeep({ foo: 'bar', hello: ['foo', 'bar'] })).toEqual(['foo', 'hello']);
|
||||
expect(getKeysDeep({ foo: 'bar', nested: { hello: ['foo', 'bar'] } })).toEqual(['foo', 'nested.hello']);
|
||||
|
|
|
@ -34,6 +34,7 @@ describe('SettingInputField component', () => {
|
|||
label: 'test-number-input',
|
||||
inputType: SettingInputFieldType.NUMBER,
|
||||
value: 5,
|
||||
required: true,
|
||||
},
|
||||
});
|
||||
const user = userEvent.setup();
|
||||
|
|
|
@ -56,7 +56,11 @@
|
|||
if (newValue > max) {
|
||||
newValue = max;
|
||||
}
|
||||
value = value === '' ? undefined : newValue;
|
||||
if (!required && value === '') {
|
||||
value = undefined;
|
||||
} else {
|
||||
value = newValue;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue