Skip to content

Commit

Permalink
refactor: remove redundant check
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesgeorge007 authored and okonet committed Apr 4, 2020
1 parent 662a3a5 commit 899d399
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions lib/runAll.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ const runAll = async (

// lint-staged 10 will automatically add modifications to index
// Warn user when their command includes `git add`
let hasDeprecatedGitAdd = false
let hasDeprecatedGitAdd

const listrOptions = {
dateFormat: false,
Expand All @@ -137,9 +137,7 @@ const runAll = async (
shell
})

if (subTasks.some(subTask => subTask.command === 'git add')) {
hasDeprecatedGitAdd = true
}
hasDeprecatedGitAdd = subTasks.some(subTask => subTask.command === 'git add')

chunkListrTasks.push({
title: `Running tasks for ${task.pattern}`,
Expand Down

0 comments on commit 899d399

Please sign in to comment.