The weeb for the next gen discord boat - Wamellow wamellow.com
bot discord
4
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: allow empty names and reset errors on file change (#61)

Allow empty strings in name validation and clear errors when selecting a
new file.

authored by

Luna Seemann and committed by
GitHub
d8c8e85b d5a66b9c

+2 -1
+2 -1
app/dashboard/[guildId]/style.component.tsx
··· 183 183 }} 184 184 onSubmit={() => { 185 185 const valid = isValidUsername(name); 186 - if (name !== "" && !valid) return new Error("Invalid name"); 186 + if (name && !valid) return new Error("Invalid name"); 187 187 188 188 const formData = new FormData(); 189 189 formData.append("json_payload", JSON.stringify({ username: name || null, bio })); ··· 282 282 accept={ALLOWED_FILE_TYPES.join()} 283 283 className="hidden" 284 284 onChange={(e) => { 285 + setError(null); 285 286 setBuf(null); 286 287 287 288 const file = e.target.files?.[0];