mirror of
https://github.com/djdevin/recflare.git
synced 2026-10-25 23:18:51 -07:00
[api] up invention limit to match client
This commit is contained in:
@@ -3584,9 +3584,9 @@ describe('public endpoints', () => {
|
||||
body: JSON.stringify({ inventionDataFilename: 'a.inv', ...fields }),
|
||||
})
|
||||
|
||||
// A name is 3–24 characters of letters, digits, spaces, dashes and colons.
|
||||
// A name is 3–40 characters of letters, digits, spaces, dashes and colons.
|
||||
expect((await save({ name: 'ab' })).status).toBe(400)
|
||||
expect((await save({ name: 'a'.repeat(25) })).status).toBe(400)
|
||||
expect((await save({ name: 'a'.repeat(41) })).status).toBe(400)
|
||||
expect((await save({ name: 'Rocket!' })).status).toBe(400)
|
||||
expect((await save({ name: 'Café Lamp' })).status).toBe(400)
|
||||
const ok = await save({ name: 'Rocket Sofa-Bed 2' })
|
||||
|
||||
@@ -58,7 +58,7 @@ export const MAX_EVENT_DURATION_MS = 24 * 60 * 60 * 1000
|
||||
* offers `Untitled` rather than an empty box.
|
||||
*/
|
||||
export const MIN_INVENTION_NAME_LENGTH = 3
|
||||
export const MAX_INVENTION_NAME_LENGTH = 24
|
||||
export const MAX_INVENTION_NAME_LENGTH = 40
|
||||
export const MAX_INVENTION_DESCRIPTION_LENGTH = 512
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user