<s> import page . utils <EOL> def renderVerifyEmail ( req , db , user ) : <EOL> if user . isAnonymous ( ) : <EOL> raise page . utils . NeedLogin ( req ) <EOL> elif req . user != user . name : <EOL> raise page . utils . DisplayMessage ( "<STR_LIT>" ) <EOL> email = req . getParameter ( "<STR_LIT:email>" ) <EOL> verification_token = req . getParameter ( "<STR_LIT>" ) <EOL> cursor = db . cursor ( ) <EOL> cursor . execute ( """<STR_LIT>""" , <EOL> ( user . id , email , verification_token ) ) <EOL> row = cursor . fetchone ( ) <EOL> if not row : <EOL> raise page . utils . DisplayMessage ( "<STR_LIT>" ) <EOL> email_id = row [ <NUM_LIT:0> ] <EOL> cursor . execute ( """<STR_LIT>""" , <EOL> ( email_id , ) ) <EOL> db . commit ( ) <EOL> raise page . utils . MovedTemporarily ( "<STR_LIT>" % email_id ) </s>
