mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-24 20:14:35 -04:00
refactor(config): type config mocks
To minimize type errors, when the config objects are changed, this commit introduces types to the mock config object accordingly. Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
parent
6c82b95ea2
commit
2d8d29cf20
4 changed files with 86 additions and 63 deletions
|
@ -1,18 +1,23 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
||||
* SPDX-FileCopyrightText: 2022 The HedgeDoc developers (see AUTHORS file)
|
||||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
import { registerAs } from '@nestjs/config';
|
||||
|
||||
export default registerAs('customizationConfig', () => ({
|
||||
branding: {
|
||||
customName: 'ACME Corp',
|
||||
customLogo: '',
|
||||
},
|
||||
specialUrls: {
|
||||
privacy: '/test/privacy',
|
||||
termsOfUse: '/test/termsOfUse',
|
||||
imprint: '/test/imprint',
|
||||
},
|
||||
}));
|
||||
import { CustomizationConfig } from '../customization.config';
|
||||
|
||||
export default registerAs(
|
||||
'customizationConfig',
|
||||
(): CustomizationConfig => ({
|
||||
branding: {
|
||||
customName: 'ACME Corp',
|
||||
customLogo: '',
|
||||
},
|
||||
specialUrls: {
|
||||
privacy: '/test/privacy',
|
||||
termsOfUse: '/test/termsOfUse',
|
||||
imprint: '/test/imprint',
|
||||
},
|
||||
}),
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue