I am executing “truffle migrate” command but I am getting one reference error related to ‘adoption’ variable:there is no error related to compilation
2_deploy_contracts.js
ReferenceError: adoption is not defined at module.exports (absolute path/2_deploy_contracts.js:5:20) at Migration._load (/usr/local/lib/node_modules/truffle/build/webpack:/packages/migrate/migration.js:56:1) at at process._tickCallback (internal/process/next_tick.js:188:7) Truffle v5.1.27 (core: 5.1.27) Node v8.10.0
The 2-deploy_contracts.js of this project is given below which does not have any adoption variable defined:
var attacker = artifacts.require("Attacker");
var victim = artifacts.require("Victim");
module.exports = function(deployer){
deployer.deploy(adoption);
deployer.deploy(victim);
};
I have defined adoption variable in another 2_deploy_contracts.js file which is given below:
var adoption = artifacts.require("adoption");
module.exports = function(deployer){
deployer.deploy(adoption);
};
Somebody please guide me why I am getting this reference error. I am running 'truffle migrate' from the root of the project
Zulfi.