1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

vweb: remove favicon hack

This commit is contained in:
Alexander Medvednikov 2019-08-02 10:15:18 +00:00
parent 8990eb06ec
commit ed3f1d315b

View File

@ -120,15 +120,10 @@ pub fn run<T>(port int) {
first_line := s.all_before('\n')
vals := first_line.split(' ')
mut action := vals[1].right(1).all_before('/')
println('vweb.v: action="$action"')
if action.contains('?') {
action = action.all_before('?')
}
if action == 'favicon.ico' {
println('favicon.ico')
conn.write('HTTP/1.1 404 Not Found')
conn.close()
continue
}
if action == '' {
action = 'index'
}