Skip to content

Commit 6704af5

Browse files
committed
fix(plugins/languages): risky type assignment
1 parent 7130b3a commit 6704af5

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

source/plugins/languages/analyzer/analyzer.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ export class Analyzer {
6464
completed = true
6565
solve(this.results)
6666
})
67-
results.partial = (results.partial.global) || (results.partial.repositories)
6867
return results
6968
}
7069

source/templates/classic/partials/languages.ejs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
</div>
8888
</div>
8989
<% } %>
90-
<% if ({"most-used":plugins.languages.partial, "recently-used":plugins.languages["stats.recent"]?.partial}[section]) { %>
90+
<% if ({"most-used":plugins.languages.partial?.global || plugins.languages.partial?.repositories, "recently-used":plugins.languages["stats.recent"]?.partial?.global || plugins.languages["stats.recent"]?.partial?.repositories}[section]) { %>
9191
<div class="row footnote warning">
9292
<div class="field">
9393
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M8.22 1.754a.25.25 0 00-.44 0L1.698 13.132a.25.25 0 00.22.368h12.164a.25.25 0 00.22-.368L8.22 1.754zm-1.763-.707c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0114.082 15H1.918a1.75 1.75 0 01-1.543-2.575L6.457 1.047zM9 11a1 1 0 11-2 0 1 1 0 012 0zm-.25-5.25a.75.75 0 00-1.5 0v2.5a.75.75 0 001.5 0v-2.5z"></path></svg>

0 commit comments

Comments
 (0)