Skip to content

Commit 4aa4ead

Browse files
committed
Fixed a bug
1 parent 3e5ce8b commit 4aa4ead

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/UserModificationUI.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,9 @@ public UserModificationUI() {
1818
// Field for username
1919
final JTextField usernameField = new JTextField("Enter your current username");
2020
usernameField.setBounds(10, 25, 100, 25);
21-
String username = (usernameField.getText());
2221

2322
// Field for password
2423
final JTextField passwordField = new JTextField("Enter your current password");
25-
String password = (passwordField.getText());
2624
passwordField.setBounds(10, 25, 100, 25);
2725

2826
// to select feature that user wants to change
@@ -43,6 +41,8 @@ public UserModificationUI() {
4341
btn.addActionListener(new ActionListener() {
4442
@Override
4543
public void actionPerformed(ActionEvent e) {
44+
String username = (usernameField.getText());
45+
String password = (passwordField.getText());
4646
String item = cb.getSelectedItem().toString();
4747
String newFeature = (passwordField.getText());
4848
boolean success = reportChange(username, password, item, newFeature);

0 commit comments

Comments
 (0)