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

vfmt: shorten main.const_name to just const_name

This commit is contained in:
Delyan Angelov
2021-01-25 13:08:43 +02:00
parent ea11488339
commit dbaccd4272
25 changed files with 183 additions and 175 deletions

View File

@@ -64,7 +64,7 @@ pub fn (mut app App) chunk() vweb.Result {
// the following serve custom routes
['/:user/settings']
pub fn (mut app App) settings(username string) vweb.Result {
if username !in main.known_users {
if username !in known_users {
return app.not_found()
}
return app.html('username: $username')
@@ -72,7 +72,7 @@ pub fn (mut app App) settings(username string) vweb.Result {
['/:user/:repo/settings']
pub fn (mut app App) user_repo_settings(username string, repository string) vweb.Result {
if username !in main.known_users {
if username !in known_users {
return app.not_found()
}
return app.html('username: $username | repository: $repository')