refactor(Compiler): simplify the code

Closes #862
This commit is contained in:
Victor Berchet 2015-03-03 15:26:18 +01:00 committed by Misko Hevery
parent 04abf2629b
commit bcf4a96a84
1 changed files with 1 additions and 2 deletions

View File

@ -150,11 +150,10 @@ export class Compiler {
// TODO(vicb): union type return ProtoView or Promise<ProtoView>
_compileTemplate(template: Template, tplElement, component: Type) {
var pipeline = new CompilePipeline(this.createSteps(component, template));
var compilationCtxtDescription = stringify(this._reader.read(component).type);
var compileElements;
try {
compileElements = pipeline.process(tplElement, compilationCtxtDescription);
compileElements = pipeline.process(tplElement, stringify(component));
} catch(ex) {
return PromiseWrapper.reject(ex);
}