Commit 57580ad2 authored by Robert Czechowski's avatar Robert Czechowski
Browse files

Redirect to profile page on contest pages if account is incomplete

parent 854dec84
Pipeline #969 passed with stages
in 16 minutes and 24 seconds
......@@ -332,6 +332,10 @@ pub fn show_contest<T: MedalConnection>(conn: &T, contest_id: i32, session_token
let session = conn.get_session_or_new(&session_token).unwrap();
if session.logincode.is_some() && session.firstname.is_none() {
return Err(MedalError::AccountIncomplete);
let contest = conn.get_contest_by_id_complete(contest_id);
let grades = conn.get_contest_user_grades(&session_token, contest_id);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment