Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

Commit bde18e2

Browse files
authored
Merge pull request #117 from Microsoft/fixSuperCall
Remove extra super call.
2 parents e725924 + e63c39b commit bde18e2

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

todomvc/js/todos.ts

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ declare module Backbone {
5757
toJSON(): any;
5858
}
5959
export class Collection<T> {
60-
constructor (models? , opts? );
60+
constructor (models?, opts?);
6161
bind(ev: string, f: Function, ctx?: any): void;
6262
length: number;
6363
create(attrs, opts? ): any;
@@ -69,7 +69,7 @@ declare module Backbone {
6969
without(...values: T[]): T[];
7070
}
7171
export class View {
72-
constructor (options? );
72+
constructor (options?);
7373
$(selector: string): JQuery;
7474
el: HTMLElement;
7575
$el: JQuery;
@@ -201,9 +201,8 @@ class TodoView extends Backbone.View {
201201
model: Todo;
202202
input: JQuery;
203203

204-
constructor (options? ) {
205-
// A call to super() is needed to avoid TS17009.
206-
super();
204+
constructor (options?) {
205+
super(options);
207206
//... is a list tag.
208207
this.tagName = "li";
209208

@@ -216,8 +215,6 @@ class TodoView extends Backbone.View {
216215
"blur .todo-input": "close"
217216
};
218217

219-
super(options);
220-
221218
// Cache the template function for a single item.
222219
this.template = _.template($('#item-template').html());
223220

0 commit comments

Comments
 (0)