mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
os: replace dir_exists with is_dir; file_exists() => exists()
This commit is contained in:
@ -153,12 +153,12 @@ fn (p mut Parser) comp_time() {
|
||||
if p.pref.is_debug {
|
||||
println('compiling tmpl $path')
|
||||
}
|
||||
if !os.file_exists(path) {
|
||||
if !os.exists(path) {
|
||||
// Can't find the template file in current directory,
|
||||
// try looking next to the vweb program, in case it's run with
|
||||
// v path/to/vweb_app.v
|
||||
path = os.dir(p.scanner.file_path) + '/' + path
|
||||
if !os.file_exists(path) {
|
||||
if !os.exists(path) {
|
||||
p.error('vweb HTML template "$path" not found')
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user