Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,10 @@ export const DialogSettings: React.FC<RouteComponentProps> = () => {
};

const handleChange = (result: any) => {
saveChangeResult(result);
// prevent result was undefined, it will cause error
if (result && typeof result === 'object') {
saveChangeResult(result);
}
};

const hostedControl = () => (
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.

import omit from 'lodash/omit';
import set from 'lodash/set';
import { SensitiveProperties } from '@bfc/shared';
import { UserIdentity } from '@bfc/plugin-loader';

Expand Down Expand Up @@ -66,7 +66,10 @@ export class DefaultSettingManager extends FileSettingManager {

private filterOutSensitiveValue = (obj: any) => {
if (obj && typeof obj === 'object') {
return omit(obj, SensitiveProperties);
SensitiveProperties.map((key) => {
set(obj, key, '');
});
return obj;
}
};

Expand Down