Chore: remove strict errors for azure-monitor (#40675)

This commit is contained in:
Andres Martinez Gotor 2021-10-20 16:34:24 +02:00 committed by GitHub
parent 0d036a6df5
commit 302fef394a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 5 deletions

View File

@ -47,8 +47,8 @@ export const onUpdateDatasourceResetOption = (props: DataSourcePluginOptionsEdit
updateDatasourcePluginResetOption(props, key);
};
export function updateDatasourcePluginOption(
props: DataSourcePluginOptionsEditorProps,
export function updateDatasourcePluginOption<J, S extends {} = KeyValue>(
props: DataSourcePluginOptionsEditorProps<J, S>,
key: keyof DataSourceSettings,
val: any
) {
@ -82,21 +82,27 @@ export const updateDatasourcePluginSecureJsonDataOption = <J, S extends {} = Key
val: any
) => {
const config = props.options;
if (!config.secureJsonData) {
return;
}
props.onOptionsChange({
...config,
secureJsonData: {
...config.secureJsonData!,
...config.secureJsonData,
[key]: val,
},
});
};
export const updateDatasourcePluginResetOption = <J, S extends {} = KeyValue>(
props: DataSourcePluginOptionsEditorProps,
props: DataSourcePluginOptionsEditorProps<J, S>,
key: string
) => {
const config = props.options;
if (!config.secureJsonData) {
return;
}
props.onOptionsChange({
...config,

View File

@ -3,7 +3,7 @@ set -e
echo -e "Collecting code stats (typescript errors & more)"
ERROR_COUNT_LIMIT=12
ERROR_COUNT_LIMIT=6
ERROR_COUNT="$(./node_modules/.bin/tsc --project tsconfig.json --noEmit --strict true | grep -oP 'Found \K(\d+)')"
if [ "$ERROR_COUNT" -gt $ERROR_COUNT_LIMIT ]; then