Closed mandarvl closed 7 months ago
I have this method in my controller :
@InMemoryCache({ key: 'facilities', kind: 'temporal', ttl: 60 * 60 * 10, paramIndex: [0] }) async loadData(@Query('someParam') param?: number) { ... }
The problem is that when userId is null (or undefined), it throw this error : TypeError : The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received null
TypeError : The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received null
Is it possible to allow optional parameters ?
Of course! I think recent update brought this bug. I'll fix it
once you update package version to 1.0.5, you'll get fixed package. thanks for contribution!
Thank you, will try it asap!
I have this method in my controller :
The problem is that when userId is null (or undefined), it throw this error :
TypeError : The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received null
Is it possible to allow optional parameters ?