Commit bd99a470 authored by Josselin ENET's avatar Josselin ENET

Fixed the bug when adding an agent #54

Fixed the bug giving the admin role when we tried to add an agent.
parent d13ede82
......@@ -55,7 +55,7 @@ public class AdminUserAdditionController extends SceneController {
else {
String name = nameTextField.getText();
String username = usernameTextField.getText();
String role = selectedRadioButton.getText().toLowerCase();
String role = selectedRadioButton.getText();
String password = passwordTextField.getText();
handleAdd(name, username, role, password);
......@@ -85,6 +85,7 @@ public class AdminUserAdditionController extends SceneController {
public void handleAdd(String name, String username, String role, String password) {
if (name.equals("")) {
AlertHandler.showAlert(ERROR, "No name specified.");
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment