chore: code formatting

This commit is contained in:
github-actions[bot]
2022-02-16 04:27:34 +00:00
parent c8c4ff9ef6
commit 5550ac0d77
2 changed files with 5 additions and 4 deletions

View File

@@ -54,7 +54,8 @@ export default async function({login, q, imports, data, rest, account}, {enabled
//Search for a random snippet
let files = events
.flatMap(({created, sha, commit:{message, url}, files}) => files.map(({filename, status, additions, deletions, patch}) => ({created, sha, message, filename, status, additions, deletions, patch, repo:url.match(/repos[/](?<repo>[\s\S]+)[/]git[/]commits/)?.groups?.repo})))
.flatMap(({created, sha, commit:{message, url}, files}) => files.map(({filename, status, additions, deletions, patch}) => ({created, sha, message, filename, status, additions, deletions, patch, repo:url.match(/repos[/](?<repo>[\s\S]+)[/]git[/]commits/)?.groups?.repo}))
)
.filter(({patch}) => (patch ? (patch.match(/\n/mg)?.length ?? 1) : Infinity) < lines)
for (const file of files)
file.language = await imports.language({...file, prefix:login}).catch(() => "unknown")

View File

@@ -275,7 +275,7 @@ export default function({ faker }, target, that, [{ username: login, page, per_p
url: "https://api.github.com/repos/lowlighter/metrics/commits/MOCKED_SHA",
author: {
email: faker.internet.email(),
}
},
},
],
},