Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
Merge pull request #5835 from trufflesuite/nix-unused-errors
Browse files Browse the repository at this point in the history
Remove unused error classes
  • Loading branch information
cds-amal committed Jan 13, 2023
2 parents eeb1661 + 4c1f068 commit 4a4f889
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 36 deletions.
11 changes: 1 addition & 10 deletions packages/core/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ require("source-map-support/register");

const semver = require("semver"); // to validate Node version
const TruffleError = require("@truffle/error");
const TaskError = require("./lib/errors/taskerror");
const analytics = require("./lib/services/analytics");
const version = require("./lib/version");
const versionInfo = version.info();
Expand Down Expand Up @@ -107,15 +106,7 @@ runCommand(command, options)
process.exit();
})
.catch(error => {
if (error instanceof TaskError) {
analytics.send({
exception: "TaskError - display general help message",
version: versionInfo.bundle
? versionInfo.bundle
: "(unbundled) " + versionInfo.core
});
command.displayGeneralHelp();
} else if (error instanceof TruffleError) {
if (error instanceof TruffleError) {
analytics.send({
exception: "TruffleError - missing configuration file",
version: versionInfo.bundle
Expand Down
17 changes: 0 additions & 17 deletions packages/core/lib/errors/deployerror.js

This file was deleted.

9 changes: 0 additions & 9 deletions packages/core/lib/errors/taskerror.js

This file was deleted.

0 comments on commit 4a4f889

Please sign in to comment.