diff --git a/server/sonar-web/src/main/js/apps/organizations/actions.js b/server/sonar-web/src/main/js/apps/organizations/actions.js
index 1782325a68e..3d732bce808 100644
--- a/server/sonar-web/src/main/js/apps/organizations/actions.js
+++ b/server/sonar-web/src/main/js/apps/organizations/actions.js
@@ -175,7 +175,12 @@ export const updateOrganizationMemberGroups = (
...add.map(id => addUserToGroup(id, member.login)),
...remove.map(id => removeUserFromGroup(id, member.login))
];
- return Promise.all(promises).then(() => {
- dispatch(receiveUser({ ...member, groupCount: member.groupCount + add.length - remove.length }));
- }, onFail(dispatch));
+ return Promise.all(promises).then(
+ () => {
+ dispatch(
+ receiveUser({ ...member, groupCount: member.groupCount + add.length - remove.length })
+ );
+ },
+ onFail(dispatch)
+ );
};
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/MembersListItem.js b/server/sonar-web/src/main/js/apps/organizations/components/MembersListItem.js
index 2324b9d4c7f..a3465c60a52 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/MembersListItem.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/MembersListItem.js
@@ -53,7 +53,10 @@ export default class MembersListItem extends React.PureComponent {
{organization.canAdmin &&
- {translateWithParameters('organization.members.x_groups', formatMeasure(member.groupCount || 0, 'INT'))}
+ {translateWithParameters(
+ 'organization.members.x_groups',
+ formatMeasure(member.groupCount || 0, 'INT')
+ )}
}
{organization.canAdmin &&
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/OrganizationDelete.js b/server/sonar-web/src/main/js/apps/organizations/components/OrganizationDelete.js
index caf6cd849ef..ece826b126b 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/OrganizationDelete.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/OrganizationDelete.js
@@ -67,8 +67,7 @@ class OrganizationDelete extends React.Component {
contentLabel="modal form"
className="modal"
overlayClassName="modal-overlay"
- onRequestClose={this.handleCloseModal}
- >
+ onRequestClose={this.handleCloseModal}>
{translate('organization.delete')}
@@ -112,8 +111,7 @@ class OrganizationDelete extends React.Component {
+ onClick={this.handleOpenModal}>
{translate('delete')}
{this.state.deleting && this.renderModal()}
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/OrganizationGroupCheckbox.js b/server/sonar-web/src/main/js/apps/organizations/components/OrganizationGroupCheckbox.js
index f21f52b0094..ffe6fc463ce 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/OrganizationGroupCheckbox.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/OrganizationGroupCheckbox.js
@@ -45,8 +45,7 @@ export default class OrganizationGroupCheckbox extends React.PureComponent {
className="capitalize list-item-checkable-link"
onClick={this.toggleCheck}
tabIndex={0}
- role="listitem"
- >
+ role="listitem">
{' '}{this.props.group.name}
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersList-test.js b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersList-test.js
index d96f62874d5..aeff08b58c7 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersList-test.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersList-test.js
@@ -28,11 +28,6 @@ const members = [
];
it('should render a list of members of an organization', () => {
- const wrapper = shallow(
-
- );
+ const wrapper = shallow( );
expect(wrapper).toMatchSnapshot();
});
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListHeader-test.js b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListHeader-test.js
index 439f998b4b7..4844a99aca1 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListHeader-test.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListHeader-test.js
@@ -22,15 +22,11 @@ import { shallow } from 'enzyme';
import MembersListHeader from '../MembersListHeader';
it('should render without the total', () => {
- const wrapper = shallow(
-
- );
+ const wrapper = shallow( );
expect(wrapper).toMatchSnapshot();
});
it('should render with the total', () => {
- const wrapper = shallow(
-
- );
+ const wrapper = shallow( );
expect(wrapper).toMatchSnapshot();
});
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListItem-test.js b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListItem-test.js
index dd97722ea42..1ed64e94cec 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListItem-test.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersListItem-test.js
@@ -26,31 +26,20 @@ const admin = { login: 'admin', name: 'Admin Istrator', avatar: '', groupCount:
const john = { login: 'john', name: 'John Doe', avatar: '7daf6c79d4802916d83f6266e24850af' };
it('should not render actions and groups for non admin', () => {
- const wrapper = shallow(
-
- );
+ const wrapper = shallow( );
expect(wrapper).toMatchSnapshot();
});
it('should render actions and groups for admin', () => {
const wrapper = shallow(
-
+
);
expect(wrapper).toMatchSnapshot();
});
it('should groups at 0 if the groupCount field is not defined (just added user)', () => {
const wrapper = shallow(
-
+
);
expect(wrapper).toMatchSnapshot();
});
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersPageHeader-test.js b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersPageHeader-test.js
index 4e8fd9a2760..1c431fbaf6f 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersPageHeader-test.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/__tests__/MembersPageHeader-test.js
@@ -22,9 +22,7 @@ import { shallow } from 'enzyme';
import MembersPageHeader from '../MembersPageHeader';
it('should render the members page header', () => {
- const wrapper = shallow(
-
- );
+ const wrapper = shallow( );
expect(wrapper).toMatchSnapshot();
wrapper.setProps({ loading: true });
expect(wrapper.find('.spinner')).toMatchSnapshot();
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/forms/AddMemberForm.js b/server/sonar-web/src/main/js/apps/organizations/components/forms/AddMemberForm.js
index 3ed2825cde5..c478be943d5 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/forms/AddMemberForm.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/forms/AddMemberForm.js
@@ -69,8 +69,7 @@ export default class AddMemberForm extends React.PureComponent {
contentLabel="modal form"
className="modal"
overlayClassName="modal-overlay"
- onRequestClose={this.closeForm}
- >
+ onRequestClose={this.closeForm}>
diff --git a/server/sonar-web/src/main/js/apps/organizations/components/forms/ManageMemberGroupsForm.js b/server/sonar-web/src/main/js/apps/organizations/components/forms/ManageMemberGroupsForm.js
index ac19d3e725f..14243d37f04 100644
--- a/server/sonar-web/src/main/js/apps/organizations/components/forms/ManageMemberGroupsForm.js
+++ b/server/sonar-web/src/main/js/apps/organizations/components/forms/ManageMemberGroupsForm.js
@@ -107,15 +107,17 @@ export default class ManageMemberGroupsForm extends React.PureComponent {
contentLabel="modal form"
className="modal"
overlayClassName="modal-overlay"
- onRequestClose={this.closeForm}
- >
+ onRequestClose={this.closeForm}>
{translate('organization.members.manage_groups')}