Skip to content

Commit

Permalink
claim contracts under node_modules on truffle project
Browse files Browse the repository at this point in the history
  • Loading branch information
antico5 committed Apr 17, 2023
1 parent cf96685 commit ed29af5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion server/src/frameworks/Truffle/TruffleProject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,8 @@ export class TruffleProject extends Project {
public async fileBelongs(file: string): Promise<FileBelongsResult> {
let belongs: boolean;
if (this.status === Status.INITIALIZED_SUCCESS) {
belongs = [this.sourcesPath, this.testsPath].some((dir) =>
const modulesPath = path.join(this.basePath, "node_modules");
belongs = [this.sourcesPath, this.testsPath, modulesPath].some((dir) =>
directoryContains(dir, path.dirname(file))
);
} else {
Expand Down

0 comments on commit ed29af5

Please sign in to comment.