pwi-plata-type 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/libs/model.ts +2 -2
- package/package.json +1 -1
package/libs/model.ts
CHANGED
|
@@ -306,7 +306,7 @@ export function Int(): ModelValicacaoPrimitivo {
|
|
|
306
306
|
|
|
307
307
|
export function isArray(tamanhoMaximo?: number): ModelValicacaoPrimitivo {
|
|
308
308
|
return async (nome: string, valor: any) => {
|
|
309
|
-
if (valor ===
|
|
309
|
+
if (valor === null) {
|
|
310
310
|
return {
|
|
311
311
|
error: {
|
|
312
312
|
errorID: "BPCVARR001",
|
|
@@ -354,7 +354,7 @@ export function Optional(): ModelValicacaoPrimitivo {
|
|
|
354
354
|
|
|
355
355
|
export function Required(): ModelValicacaoPrimitivo {
|
|
356
356
|
return async (nome: string, valor: any) => {
|
|
357
|
-
if (valor ===
|
|
357
|
+
if (valor === null) {
|
|
358
358
|
return {
|
|
359
359
|
error: {
|
|
360
360
|
errorID: "BPCVREQ001",
|