mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-06 05:25:50 +01:00
Small cleanup using static analysis
This commit is contained in:
@@ -59,7 +59,7 @@ trait IndexControllerBase extends ControllerBase {
|
||||
updateLastLoginDate(account.userName)
|
||||
|
||||
flash.get(Keys.Flash.Redirect).asInstanceOf[Option[String]].map { redirectUrl =>
|
||||
if(redirectUrl.replaceFirst("/$", "") == request.getContextPath){
|
||||
if(redirectUrl.stripSuffix("/") == request.getContextPath){
|
||||
redirect("/")
|
||||
} else {
|
||||
redirect(redirectUrl)
|
||||
|
||||
Reference in New Issue
Block a user