From 5542be041890fb9f438a0b2f03a764579d2f119e Mon Sep 17 00:00:00 2001 From: Jef Roosens Date: Mon, 7 Nov 2022 21:13:40 +0100 Subject: [PATCH] fix(api): set arch if not provided or empty (fixes #278) --- src/server/api_targets.v | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/api_targets.v b/src/server/api_targets.v index 6f284af6..c4d32d24 100644 --- a/src/server/api_targets.v +++ b/src/server/api_targets.v @@ -32,7 +32,7 @@ fn (mut app App) v1_post_target() web.Result { // If a repo is created without specifying the arch, we assume it's meant // for the default architecture. - if 'arch' !in params { + if 'arch' !in params || params['arch'] == '' { params['arch'] = app.conf.default_arch }