Skip to content

Commit 5d58c07

Browse files
greenkeeper[bot]goto-bus-stop
authored andcommitted
Update eslint-config-airbnb-base to the latest version 🚀 (#35)
* chore(package): update eslint-config-airbnb-base to version 11.0.0 https://greenkeeper.io/ * Fix lint errors.
1 parent 49f97f5 commit 5d58c07

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
"babel-preset-es2015-node4": "^2.1.0",
3131
"babel-preset-stage-2": "^6.5.0",
3232
"eslint": "^3.1.1",
33-
"eslint-config-airbnb-base": "^10.0.0",
33+
"eslint-config-airbnb-base": "^11.0.0",
3434
"eslint-plugin-import": "^2.0.1"
3535
},
3636
"scripts": {

src/index.js

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,9 @@ export default function youTubeSource(uw, opts = {}) {
183183
const playlistItems = [];
184184
try {
185185
do {
186+
// This `await` is OK since we need to fetch this page to find out how
187+
// to fetch the next.
188+
// eslint-disable-next-line no-await-in-loop
186189
const res = await getPlaylistPage(playlistID, page);
187190
page = res.nextPage;
188191
playlistItems.push(...res.items);
@@ -291,6 +294,9 @@ export default function youTubeSource(uw, opts = {}) {
291294
const playlists = [];
292295
let page;
293296
do {
297+
// This `await` is OK since we need to fetch this page to find out how
298+
// to fetch the next.
299+
// eslint-disable-next-line no-await-in-loop
294300
const res = await getChannelPlaylistsPage(channelID, page);
295301
page = res.nextPage;
296302
playlists.push(...res.items);
@@ -332,23 +338,23 @@ export default function youTubeSource(uw, opts = {}) {
332338

333339
async function doImport(ctx, name, playlistID) {
334340
const items = await getPlaylistItems(playlistID);
335-
return await ctx.createPlaylist(name, items);
341+
return ctx.createPlaylist(name, items);
336342
}
337343

338344
return {
339345
search,
340346
get: get, // eslint-disable-line object-shorthand
341347
async import(ctx, action) {
342348
if (action.action === 'channel') {
343-
return await getPlaylistMetasForUser(action.url);
349+
return getPlaylistMetasForUser(action.url);
344350
}
345351
if (action.action === 'playlist') {
346352
const importable = await getImportablePlaylist(action.url);
347353
importable.items = ctx.source.addSourceType(importable.items);
348354
return importable;
349355
}
350356
if (action.action === 'importplaylist') {
351-
return await doImport(ctx, action.name, action.id);
357+
return doImport(ctx, action.name, action.id);
352358
}
353359

354360
throw new TypeError(`Unknown action "${action}"`);

0 commit comments

Comments
 (0)