Make trailing slash optional in URLs

This commit is contained in:
Bálint Bokros 2018-02-09 14:05:34 +01:00
parent 1c3e946e29
commit e39b8b9283

View File

@ -9,8 +9,8 @@ from tfw.networking.solvable_connector import SolvableConnector
if __name__ == '__main__':
solvable_connector = SolvableConnector()
routes = [
(r'/{secret}/'.format(secret=AVATAO_SECRET), SolutionCheckHandler, {'solvable_connector': solvable_connector}),
(r'/{secret}/test'.format(secret=AVATAO_SECRET), TestHandler, {'solvable_connector': solvable_connector})
(r'/{secret}/?'.format(secret=AVATAO_SECRET), SolutionCheckHandler, {'solvable_connector': solvable_connector}),
(r'/{secret}/test/?'.format(secret=AVATAO_SECRET), TestHandler, {'solvable_connector': solvable_connector})
]
app = Application(
routes