(values)
| 13953 | |
| 13954 | if (!mustHaveExpression || expressions.length) { |
| 13955 | var compute = function(values) { |
| 13956 | for (var i = 0, ii = expressions.length; i < ii; i++) { |
| 13957 | if (allOrNothing && isUndefined(values[i])) return; |
| 13958 | concat[expressionPositions[i]] = values[i]; |
| 13959 | } |
| 13960 | |
| 13961 | if (contextAllowsConcatenation) { |
| 13962 | // If `singleExpression` then `concat[0]` might be a "trusted" value or `null`, rather than a string |
| 13963 | return $sce.getTrusted(trustedContext, singleExpression ? concat[0] : concat.join('')); |
| 13964 | } else if (trustedContext && concat.length > 1) { |
| 13965 | // This context does not allow more than one part, e.g. expr + string or exp + exp. |
| 13966 | $interpolateMinErr.throwNoconcat(text); |
| 13967 | } |
| 13968 | // In an unprivileged context or only one part: just concatenate and return. |
| 13969 | return concat.join(''); |
| 13970 | }; |
| 13971 | |
| 13972 | return extend(function interpolationFn(context) { |
| 13973 | var i = 0; |
no test coverage detected