a11y-outline

web extension to navigate document outlines easily
git clone https://git.ce9e.org/a11y-outline.git

commit
91736e39fa067655d51bedc578d95169d6b5595e
parent
c2f5db6918def293949d4504a2bc92d468ee20df
Author
Tobias Bengfort <tobias.bengfort@posteo.de>
Date
2024-06-20 06:26
refactor wrap()

Diffstat

M bg.js 6 +-----

1 files changed, 1 insertions, 5 deletions


diff --git a/bg.js b/bg.js

@@ -2,11 +2,7 @@
    2     2 
    3     3 var wrap = function(fn) {
    4     4 	return function(...args) {
    5    -1 		return new Promise((resolve) => {
    6    -1 			fn(...args, result => {
    7    -1 				resolve(result);
    8    -1 			});
    9    -1 		});
   -1     5 		return new Promise(resolve => fn(...args, resolve));
   10     6 	};
   11     7 };
   12     8