forgejo/templates/user
Nils Goroll d934e0c9fb chore: refactor signup logic (#10915)
This PR is in preparation of, but independent of, an upcoming suggestion for a feature addition:

* The first commit moves a tiny bit of logic into a separate function to prepare for extension of that logic, avoiding duplication
* The second commit moves checking for disabled registrations earlier, which, I think, has merits in terms of performance and resilience (hopefully not significant, but who knows?)
* The third commit adds simple unit tests for SignUp() and SignUpPost() to avoid the long-ish roundtrip over integration tests
*  The forth commit introduces `ctx.Data["DisableRegistrationReason"]` for the signup template to use as the reason printed if `.DisableRegistration` to prepare for other reasons to be added

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/10915
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
Co-authored-by: Nils Goroll <nils.goroll@uplex.de>
Co-committed-by: Nils Goroll <nils.goroll@uplex.de>
2026-01-26 22:55:30 +01:00
..
auth chore: refactor signup logic (#10915) 2026-01-26 22:55:30 +01:00
dashboard feat(issue-search): support query syntax (#9109) 2025-11-19 16:05:42 +01:00
notification chore: remove obsolete code from button-legacy.css (#10581) 2025-12-31 03:13:05 +01:00
overview feat(UI): add package counter to repo/user/org overview pages 2024-07-31 12:40:24 +02:00
settings feat: add manage_password to user disable features (#10541) 2026-01-26 18:58:39 +01:00
code.tmpl Unify search boxes (#29530) 2024-03-20 12:31:05 +00:00
heatmap.tmpl Fix heatmap localization 2024-03-20 08:20:08 +01:00
profile.tmpl feat: allow any README for .profile (#8798) 2025-09-01 13:58:00 +02:00