prettier --write

This commit is contained in:
RainLoop Team 2019-07-04 22:19:24 +03:00
parent 450528ff00
commit 8a0be3212d
164 changed files with 7053 additions and 9008 deletions

View file

@ -1,4 +1,3 @@
import window from 'window';
// let rainloopCaches = window.caches && window.caches.open ? window.caches : null;
@ -9,19 +8,15 @@ import window from 'window';
* @returns {Promise}
*/
export function jassl(src, async = false) {
if (!window.Promise || !window.Promise.all)
{
if (!window.Promise || !window.Promise.all) {
throw new Error('Promises are not available your environment.');
}
if (!src)
{
if (!src) {
throw new Error('src should not be empty.');
}
return new window.Promise((resolve, reject) => {
const element = window.document.createElement('script');
element.onload = () => {
@ -36,7 +31,7 @@ export function jassl(src, async = false) {
element.src = src;
window.document.body.appendChild(element);
})/* .then((s) => {
}) /* .then((s) => {
const found = s && rainloopCaches ? s.match(/rainloop\/v\/([^\/]+)\/static\//) : null;
if (found && found[1])