Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,6 @@ public String save() {
} catch (ConfirmEmailException ex) {
logger.log(Level.INFO, "Unable to send email confirmation link to user id {0}", savedUser.getId());
}
session.setUser(currentUser);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it make sense here to setUser to the savedUser from line 372?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I actually tried this first but didn't take good notes. Using savedUser doesn't help.

When you save the email change you get this in server.log and go to "My Data"

[2022-04-25T11:58:34.093-0400] [Payara 5.2021.5] [WARNING] [jsf.externalcontext.flash.response.already.committed] [javax.enterprise.resource.webcontainer.jsf.flash] [tid: _ThreadID=121 _ThreadName=http-thread-pool::http-listener-1(5)] [timeMillis: 1650902314093] [levelValue: 900] [[
JSF1095: The response was already committed by the time we tried to set the outgoing cookie for the flash. Any values stored to the flash will not be available on the next request.]]

Screen Shot 2022-04-25 at 11 59 03 AM

Then, if you click "Account Information" you get a stacktrace and and empty tab:

[2022-04-25T11:59:15.297-0400] [Payara 5.2021.5] [SEVERE] [] [javax.enterprise.resource.webcontainer.jsf.context] [tid: _ThreadID=121 _ThreadName=http-thread-pool::http-listener-1(5)] [timeMillis: 1650902355297] [levelValue: 1000] [[
java.lang.IndexOutOfBoundsException: Index 2 out of bounds for length 2

Screen Shot 2022-04-25 at 11 59 28 AM

JsfHelper.addSuccessMessage(BundleUtil.getStringFromBundle("confirmEmail.changed", args));
} else {
JsfHelper.addFlashMessage(msg.toString());
Expand Down