Merge ~gary-wzl77/charm-grafana:fix-1967046 into charm-grafana:master
Status: | Work in progress |
---|---|
Proposed branch: | ~gary-wzl77/charm-grafana:fix-1967046 |
Merge into: | charm-grafana:master |
Diff against target: |
96 lines (+25/-20) 2 files modified
src/README.md (+1/-1) src/actions/create-user (+24/-19) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Alvaro Uria (community) | Needs Fixing | ||
BootStack Reviewers | mr tracking; do not claim | Pending | |
BootStack Reviewers | Pending | ||
BootStack Reviewers | Pending | ||
Review via email: mp+417845@code.launchpad.net |
Commit message
fix(actions): do not add a user to the organisation again after an account has been created
By default, when creating a user with no parameter `OrgId` is specified
in the post body, the newly created user will be added to the same
organization where the admin account belongs to. Therefore there is
no need to add the user to the organisation again.
Adding the user to the organisation again causes the following error
to occur
```
{"message":"User is already member of this organization"
```
This change fixed the issue LP:1967046.
Test: run the following command and check if the user can be added
successfully
```
juju run-action --wait grafana/0 create-user name="doe" \
<email address hidden>" \
```
This merge proposal is being monitored by mergebot. Change the status to Approved to merge.