From 3501da773f591f569398424f13b751b995dbe3b1 Mon Sep 17 00:00:00 2001 From: tdurieux Date: Mon, 26 Apr 2021 06:18:31 +0200 Subject: [PATCH] update linguist package --- utils/file.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/utils/file.js b/utils/file.js index 8a43587..80e7c63 100644 --- a/utils/file.js +++ b/utils/file.js @@ -3,7 +3,7 @@ const fs = require("fs").promises; const path = require("path"); const { Octokit } = require("@octokit/rest"); const gh = require("parse-github-url"); -const loc = require("@umijs/linguist"); +const loc = require("github-linguist").default; const { isText } = require("istextorbinary"); const db = require("./database"); @@ -464,8 +464,8 @@ module.exports.getStats = async (options) => { } catch (error) { throw "repo_not_found"; } - const o = loc(repoCache); - + const o = await loc(repoCache); + delete o.files; await db.get("anonymized_repositories").updateOne( { repoId: repoConfig.repoId }, {