Skip to content

New accounts default to text when a phone number is on file (v1.16.0) - #107

Merged
Isorgcom merged 2 commits into
mainfrom
GameNight-SignupSms
Nov 3, 2026
Merged

Isorgcom merged 2 commits into
mainfrom
GameNight-SignupSms

Conversation

@Isorgcom

@Isorgcom Isorgcom commented Nov 3, 2026

Copy link
Copy Markdown
Owner

New accounts default to text when a phone number is on file. A sign-up that gave both an email address and a phone number used to start on Email; it now starts on SMS (WhatsApp when that was the choice at sign-up), and only an account with no phone starts on Email. The rule applies everywhere an account is made: the sign-up page, the walk-in door page, the API's user create (a preferred_contact the caller sends still wins), the admin CSV import (when the preferred_contact column is blank) and the admin Add User form. Existing accounts are untouched, and everyone can still change the choice under Settings. (register_user() in www/auth.php, www/walkin.php, www/api/v1/users.php, www/admin_settings.php.)

A league holding an API key can be deleted. Deleting such a league answered "Delete failed: FOREIGN KEY constraint failed", and the same failure stopped the account deletion of its last member, whose league is removed with them. delete_league_cascade() in www/db.php now removes the league's keys and their request log first.

Verified on dev: the new signup_default_sms_check.js 21/21 (every creation path plus the cascade), walkin 9, walkin_guard 21, account_guard 36, low_hardening 44, invite_identity 31, the generated-JavaScript sweep 37 pages clean, the five greps empty.

🤖 Generated with Claude Code

Isorgcom and others added 2 commits November 3, 2026 18:46
A sign-up that gave both an email address and a phone number used to start
on Email; it now starts on SMS (WhatsApp when that was the choice at
sign-up), and only an account with no phone starts on Email. The rule
applies at register_user(), the walk-in page, the API's user create (a sent
preferred_contact still wins), the admin CSV import and the admin Add User
form. Also: delete_league_cascade() removes the league's API keys and their
request log first, so a league holding a key can be deleted and its last
member's account deletion no longer dies on the foreign key.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@Isorgcom
Isorgcom merged commit 01c42bf into main Nov 3, 2026
@Isorgcom
Isorgcom deleted the GameNight-SignupSms branch November 3, 2026 18:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant