perf(all): minify better by using arrow functions (#18730)

This commit is contained in:
Manu MA
2019-07-10 16:33:33 +02:00
committed by Brandy Carney
parent 8beeff2c52
commit 03c1d19e07
99 changed files with 653 additions and 679 deletions

View File

@ -7,7 +7,7 @@ interface HandlerRegister {
handler: Handler;
}
export function startHardwareBackButton() {
export const startHardwareBackButton = () => {
const doc = document;
let busy = false;
@ -41,9 +41,9 @@ export function startHardwareBackButton() {
executeAction(selectedHandler).then(() => busy = false);
}
});
}
};
async function executeAction(handler: Handler | undefined) {
const executeAction = async (handler: Handler | undefined) => {
try {
if (handler) {
const result = handler();
@ -54,4 +54,4 @@ async function executeAction(handler: Handler | undefined) {
} catch (e) {
console.error(e);
}
}
};