made draft seasons redirect to season_league view
This commit is contained in:
@@ -2,6 +2,7 @@ package handlers
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"net/http"
|
||||
|
||||
"git.haelnorr.com/h/golib/hws"
|
||||
@@ -41,6 +42,9 @@ func SeasonPage(
|
||||
}); !ok {
|
||||
return
|
||||
}
|
||||
if season.Type == db.SeasonTypeDraft.String() {
|
||||
http.Redirect(w, r, fmt.Sprintf("/seasons/%s/leagues/%s", season.ShortName, "Draft"), http.StatusTemporaryRedirect)
|
||||
}
|
||||
renderSafely(seasonsview.DetailPage(season, leaguesWithTeams), s, r, w)
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user