MCPcopy Index your code
hub / github.com/jquery/esprima / assertArg

Function assertArg

test/3rdparty/angular-1.2.5.js:1356–1361  ·  view source on GitHub ↗

* throw error if the argument is falsy.

(arg, name, reason)

Source from the content-addressed store, hash-verified

1354 * throw error if the argument is falsy.
1355 */
1356function assertArg(arg, name, reason) {
1357 if (!arg) {
1358 throw ngMinErr('areq', "Argument '{0}' is {1}", (name || '?'), (reason || "required"));
1359 }
1360 return arg;
1361}
1362
1363function assertArgFn(arg, name, acceptArrayAnnotation) {
1364 if (acceptArrayAnnotation && isArray(arg)) {

Callers 3

assertArgFnFunction · 0.85
$CompileProviderFunction · 0.85
compileFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…