Skip to content

Commit

Permalink
Fixed Group Configuration and Management configuration error after tr…
Browse files Browse the repository at this point in the history
…ying to going back after you save (#3672)

* Solving error

* Adding Changelog.md

* Fixing bug editting user
  • Loading branch information
Alejandro Cuéllar Peinado authored Nov 3, 2021
1 parent cc5a155 commit e02558d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ All notable changes to the Wazuh app project will be documented in this file.
- Fixed interative register windows agent screen error [#3654](https://github.com/wazuh/wazuh-kibana-app/pull/3654)
- Fixed breadcrumbs style compatibility for Kibana 7.14.2 [#3668](https://github.com/wazuh/wazuh-kibana-app/pull/3668)
- Fixed Wazuh token is not removed after logout in Kibana 7.13 [#3670](https://github.com/wazuh/wazuh-kibana-app/pull/3670)
- Fixed Group Configuration and Management configuration error after trying to going back after you save [#3672](https://github.com/wazuh/wazuh-kibana-app/pull/3672)
- Fixing EuiPannels in Overview Sections and disabled text in WzMenu [#3674](https://github.com/wazuh/wazuh-kibana-app/pull/3674)
- Fixing double flyout clicking in a policy [#3676](https://github.com/wazuh/wazuh-kibana-app/pull/3676)

Expand Down
2 changes: 1 addition & 1 deletion public/components/security/users/components/edit-user.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ export const EditUser = ({ currentUser, closeFlyout, rolesObject }) => {
useEffect(() => {
if (
initialPassword != password || initialPassword != confirmPassword ||
!_.isEqual(userRolesFormatted, selectedRoles) || allowRunAs
!_.isEqual(userRolesFormatted, selectedRoles) || allowRunAs !== currentUser.allow_run_as
) {
setHasChanges(true);
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class WzEditConfiguration extends Component {
this.props.clusterNodeSelected
)
: await saveFileManager(this.state.editorValue);
this.setState({ saving: false, infoChangesAfterRestart: true });
this.setState({ saving: false, infoChangesAfterRestart: true, hasChanges: false });
this.addToast({
title: (
<Fragment>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ class WzGroupsEditor extends Component {
this.showToast('warning', warning.savedMessage, error, 3000);
return;
}
this.setState({ isSaving: false });
this.setState({ isSaving: false, hasChanges: false });
const textSuccess = 'File successfully edited';
this.showToast('success', 'Success', textSuccess, 3000);
} catch (error) {
Expand Down

0 comments on commit e02558d

Please sign in to comment.