* throw error if the argument is falsy.
(arg, name, reason)
| 1821 | * throw error if the argument is falsy. |
| 1822 | */ |
| 1823 | function assertArg(arg, name, reason) { |
| 1824 | if (!arg) { |
| 1825 | throw ngMinErr('areq', "Argument '{0}' is {1}", (name || '?'), (reason || "required")); |
| 1826 | } |
| 1827 | return arg; |
| 1828 | } |
| 1829 | |
| 1830 | function assertArgFn(arg, name, acceptArrayAnnotation) { |
| 1831 | if (acceptArrayAnnotation && isArray(arg)) { |
no outgoing calls
no test coverage detected