diff --git a/hubsrht/blueprints/projects.py b/hubsrht/blueprints/projects.py index 68a8aac..16ad3fe 100644 --- a/hubsrht/blueprints/projects.py +++ b/hubsrht/blueprints/projects.py @@ -147,7 +147,7 @@ def create_POST(): valid = Validation(request) name = valid.require("name") description = valid.require("description") - raw_tags = valid.require("tags") + raw_tags = valid.optional("tags") visibility = valid.require("visibility", cls=Visibility) valid.expect(not name or len(name) < 128, "Name must be fewer than 128 characters", field="name") @@ -191,7 +191,7 @@ def config_POST(owner, project_name): valid = Validation(request) description = valid.require("description") - tags = _verify_tags(valid, valid.require("tags")) + tags = _verify_tags(valid, valid.optional("tags")) website = valid.optional("website") visibility = valid.require("visibility", cls=Visibility) valid.expect(not website or valid_url(website), diff --git a/hubsrht/templates/project-config.html b/hubsrht/templates/project-config.html index b52e698..6548b19 100644 --- a/hubsrht/templates/project-config.html +++ b/hubsrht/templates/project-config.html @@ -41,8 +41,7 @@ id="tags" name="tags" placeholder="Up to three comma-separated topics" - value="{{tags or ", ".join(project.tags)}}" - required /> + value="{{tags or ", ".join(project.tags)}}" /> {{valid.summary("tags")}}
diff --git a/hubsrht/templates/project-create.html b/hubsrht/templates/project-create.html index 66d0a67..26cde7f 100644 --- a/hubsrht/templates/project-create.html +++ b/hubsrht/templates/project-create.html @@ -51,7 +51,6 @@ name="tags" class="form-control {{valid.cls("tags")}}" placeholder="Up to three comma-separated topics" - required value="{{", ".join(tags) or ""}}" /> {{valid.summary("tags")}}