LPS-39744 Revert most of "LPS-38290 when there is an error in the login portlet we loose the page we were at" in order to use a better fix

This reverts commit 493c0d40d5c6aa6e44b1af673ff5367f55988ba9.
This reverts commit 7d48137d2d189808e09d30197233ee6f49c7e87c.
This reverts commit 172af6e0281920c97d915b81aca58008fb0c0dcb.
This reverts commit a00570f5ff554f52f275d24fdb723ec9eb3d77d2.

This leaves window maximized
LPS-39744 Instructing not to save lastPath on login failure
LPS-39744 Source formatting