Skip to content

Commit 10f7aab

Browse files
committed
Adjust minimatch again
1 parent dc28137 commit 10f7aab

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

  • .github/actions/https-everywhere-labeller

.github/actions/https-everywhere-labeller/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ const github = require('@actions/github');
55
const axios = require('axios');
66
const unzip = require('unzipper');
77
const context = github.context;
8-
const minimatch = require('minimatch').Minimatch;
8+
const minimatch = require('minimatch');
99
const rulesetGlob = '/src/chrome/content/rules/*.xml';
1010

1111
let ProgressBar = require('progress');
@@ -95,13 +95,13 @@ async function run(alexa) {
9595
const fileList = response.data
9696
console.log(fileList);
9797

98-
if (!fileList.every(file => new minimatch.match(file.filename, rulesetGlob, { matchBase: true }))) {
98+
if (!fileList.every(file => minimatch(file.filename, rulesetGlob))) {
9999
// Don't touch PRs that modify anything except rulesets
100100
console.log('No ruleset files in this PR');
101101
return;
102102
} else {
103103
fileList.forEach(file => {
104-
if(new minimatch.match(file.filename, rulesetGlob, { matchBase: true })){
104+
if(minimatch(file.filename, rulesetGlob)){
105105
console.log('passed match');
106106

107107
// Look at PR changes directly

0 commit comments

Comments
 (0)