File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -77,16 +77,16 @@ function checkBrowserFeatures() {
77
77
const featureList = Object . keys ( window . Modernizr ) ;
78
78
79
79
let featureComplete = true ;
80
- for ( let i = 0 ; i < featureList . length ; i ++ ) {
81
- if ( window . Modernizr [ featureList [ i ] ] === undefined ) {
80
+ for ( const feature of featureList ) {
81
+ if ( window . Modernizr [ feature ] === undefined ) {
82
82
logger . error (
83
83
"Looked for feature '%s' but Modernizr has no results for this. " +
84
- "Has it been configured correctly?" , featureList [ i ] ,
84
+ "Has it been configured correctly?" , feature ,
85
85
) ;
86
86
return false ;
87
87
}
88
- if ( window . Modernizr [ featureList [ i ] ] === false ) {
89
- logger . error ( "Browser missing feature: '%s'" , featureList [ i ] ) ;
88
+ if ( window . Modernizr [ feature ] === false ) {
89
+ logger . error ( "Browser missing feature: '%s'" , feature ) ;
90
90
// toggle flag rather than return early so we log all missing features rather than just the first.
91
91
featureComplete = false ;
92
92
}
Original file line number Diff line number Diff line change @@ -102,7 +102,7 @@ const setupCompleted = (async () => {
102
102
103
103
const handleAction = (
104
104
action : WidgetApiAction ,
105
- handler : ( request : IWidgetApiRequestData ) => void ,
105
+ handler : ( request : IWidgetApiRequestData ) => Promise < void > ,
106
106
) : void => {
107
107
widgetApi . on ( `action:${ action } ` , async ( ev : CustomEvent < IWidgetApiRequest > ) => {
108
108
ev . preventDefault ( ) ;
You can’t perform that action at this time.
0 commit comments