mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
Improved ESLint configuration, integrated spellcheck and error fixes (#8931)
* integrate cspell with eslint, improved configuration * core: fix linting errors * core: fix lint warnings * content: lint fixes * process service lint fixes * lint: process services cloud * lint: insights * lint: extensions * [ci:force] lint: cli fixes * [ci:force] comment out dead code * [ci:force] exclude dead code * fix code and tests * rollback some changes * fix testing lib * fix demo shell * minor lint warning fixes * minor lint fixes * fix process services
This commit is contained in:
@@ -123,7 +123,7 @@ export class ExtensionService {
|
||||
*/
|
||||
getFeature<T = any[]>(key: string | string[], defaultValue: any = []): T {
|
||||
const properties: string[] = Array.isArray(key) ? key : key.split('.');
|
||||
return properties.reduce((prev, curr) => prev && prev[curr], this.features) || defaultValue;
|
||||
return properties.reduce((prev, curr) => prev?.[curr], this.features) || defaultValue;
|
||||
}
|
||||
|
||||
getElements<T extends ExtensionElement>(key: string, fallback: Array<T> = []): Array<T> {
|
||||
|
Reference in New Issue
Block a user