Remove unnecessary async, explain *Async in a comment

This commit is contained in:
Ilya Ig. Petrov 2019-02-24 16:45:06 +00:00
parent 68df622d71
commit 2ce48cbd50

View File

@ -19,6 +19,14 @@
*/
/*
Due to History
- *Async suffix usually means that function requires a cb.
It may not be related to async (returning a Promise).
This naming is confusing and should be reconsidered.
*/
{ // Private namespace starts.
const mandatory = window.utils.mandatory;
@ -97,7 +105,7 @@
};
const setPacScriptFromProviderAsync = async function setPacScriptFromProviderAsync(
const setPacScriptFromProviderAsync = function setPacScriptFromProviderAsync(
provider, lastModifiedStr = mandatory(), cb = throwIfError
) {