vweb: fix actions with ?

pull/1408/head
Alexander Medvednikov 2019-08-01 17:57:01 +02:00
parent 3cd88cbb6f
commit 3580179602
1 changed files with 3 additions and 0 deletions

View File

@ -84,6 +84,9 @@ pub fn run<T>(port int) {
first_line := s.all_before('\n')
vals := first_line.split(' ')
mut action := vals[1].right(1).all_before('/')
if action.contains('?') {
action = action.all_before('?')
}
if action == '' {
action = 'index'
}