MCPcopy
hub / github.com/gitroomhq/postiz-app / q

Function q

apps/frontend/public/f.js:414–458  ·  view source on GitHub ↗
(a, b, f)

Source from the content-addressed store, hash-verified

412 : q(a, b, c);
413 }
414 function q(a, b, f) {
415 f = f.validationSchema;
416 var h = [];
417 for (var i in f)
418 if (j.call(f, i)) {
419 var k = f[i],
420 l = b[i];
421 if (k) {
422 if (k.isRequired != null && !j.call(b, i))
423 return m({
424 eventName: a,
425 param: i,
426 type: 'REQUIRED_PARAM_MISSING',
427 });
428 if (k.type != null && typeof k.type === 'string') {
429 var o = !0;
430 switch (k.type) {
431 case d:
432 k =
433 (typeof l === 'string' || typeof l === 'number') &&
434 c.test('' + l);
435 k &&
436 Number(l) < 0 &&
437 h.push({
438 eventName: a ? a : 'null',
439 param: i,
440 type: 'NEGATIVE_EVENT_PARAM',
441 });
442 o = k;
443 break;
444 case e:
445 o = typeof l === 'string' && !!g[l.toUpperCase()];
446 break;
447 }
448 if (!o)
449 return m({
450 eventName: a,
451 param: i,
452 type: 'INVALID_PARAM',
453 });
454 }
455 }
456 }
457 return n(h);
458 }
459 function r(a, c) {
460 a = p(a, c);
461 a.error && b(a.error);

Callers 9

pFunction · 0.85
rFunction · 0.85
sFunction · 0.85
aaFunction · 0.85
baFunction · 0.85
iaFunction · 0.85
aFunction · 0.85
EaFunction · 0.85
f.jsFile · 0.85

Calls 11

mFunction · 0.85
nFunction · 0.85
oFunction · 0.85
cFunction · 0.85
dFunction · 0.85
lFunction · 0.85
iFunction · 0.85
eFunction · 0.85
gFunction · 0.85
hFunction · 0.85
pFunction · 0.85

Tested by

no test coverage detected