File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -122,7 +122,7 @@ export class Application extends Context {
122
122
const ctor = target as Constructor < T > ;
123
123
key = `servers.${ ctor . name } ` ;
124
124
}
125
- return ( await this . get ( key ) ) as T ;
125
+ return await this . get < T > ( key ) ;
126
126
}
127
127
128
128
/**
@@ -156,7 +156,7 @@ export class Application extends Context {
156
156
const bindings = this . find ( `${ CoreBindings . SERVERS } .*` ) ;
157
157
await Promise . all (
158
158
bindings . map ( async binding => {
159
- const server = ( await this . get ( binding . key ) ) as Server ;
159
+ const server = await this . get < Server > ( binding . key ) ;
160
160
return await fn ( server ) ;
161
161
} ) ,
162
162
) ;
@@ -191,7 +191,7 @@ export class Application extends Context {
191
191
. inScope ( BindingScope . SINGLETON )
192
192
. tag ( 'component' ) ;
193
193
// Assuming components can be synchronously instantiated
194
- const instance = this . getSync ( componentKey ) ;
194
+ const instance = this . getSync < Component > ( componentKey ) ;
195
195
mountComponent ( this , instance ) ;
196
196
}
197
197
}
You can’t perform that action at this time.
0 commit comments