Commit bcb65be
fix: validate domain search query includes TLD (#220)
* fix: validate domain search query includes TLD
When searching without a TLD (e.g., `zeabur domain search antnest`),
the API returns `{"available": false, "tld": ""}` which is misleading.
Users may think the domain is taken when it was just an invalid query.
Add validation to require a dot in the domain name and show a helpful
error message guiding users to provide a full domain with TLD.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* refactor: use ContainsRune for single character
---------
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: Yi-Jyun Pan <pan93412@gmail.com>1 parent 7b135b7 commit bcb65be
1 file changed
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
| |||
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
46 | 51 | | |
47 | 52 | | |
48 | 53 | | |
| |||
0 commit comments