Updated CI Dockerfile; fixed formatting & vet
Some checks failed
ci/woodpecker/push/deploy unknown status
ci/woodpecker/push/docker unknown status
ci/woodpecker/push/lint Pipeline was successful
ci/woodpecker/push/build Pipeline was successful

This commit is contained in:
Jef Roosens 2022-02-22 08:14:20 +01:00
parent 6194a3f408
commit 27f59c6664
Signed by: Jef Roosens
GPG key ID: B580B976584B5F30
7 changed files with 21 additions and 11 deletions

View file

@ -42,7 +42,7 @@ fn write_repos(path string, repos []GitRepo) ? {
}
['/api/repos'; get]
pub fn (mut app App) get_repos() web.Result {
fn (mut app App) get_repos() web.Result {
if !app.is_authorized() {
return app.text('Unauthorized.')
}
@ -59,7 +59,7 @@ pub fn (mut app App) get_repos() web.Result {
}
['/api/repos'; post]
pub fn (mut app App) post_repo() web.Result {
fn (mut app App) post_repo() web.Result {
if !app.is_authorized() {
return app.text('Unauthorized.')
}
@ -98,7 +98,7 @@ pub fn (mut app App) post_repo() web.Result {
}
['/api/repos'; delete]
pub fn (mut app App) delete_repo() web.Result {
fn (mut app App) delete_repo() web.Result {
if !app.is_authorized() {
return app.text('Unauthorized.')
}

View file

@ -19,6 +19,7 @@ pub mut:
git_mutex shared util.Dummy
}
// server starts the web server & starts listening for requests
pub fn server() ? {
conf := env.load<env.ServerConfig>() ?