• 카테고리

    질문 & 답변
  • 세부 분야

    블록체인

  • 해결 여부

    미해결

안녕하세요. Visibility for constructor is ignored. If you want the contract to be non-deployable, making it "abstract" is sufficient.

21.05.07 17:24 작성 조회수 167

1

안녕하세요 강사님. 질문드릴게 있어요 ㅜ.

Lottery.sol을 만들고 생성자 입력시

constructor() public 부분에 밑줄이 나오고 해당 문제가 보여지는데 이거 문제 없는 건가요?

Visibility for constructor is ignored. If you want the contract to be non-deployable, making it "abstract" is sufficient.

그리고 Migrations.sol 파일에 

modifier restricted() {

    require(

      msg.sender == owner,

      "This function is restricted to the contract's owner"

    );

    _;

  }

처럼 선생님과 다르게 나오네요 ㅜ

마지막으로 이 2가지 때문인지는 모르지만 Lottery.sol을 다 입력 후 truffle migrate --reset 입력하면 사용된 가스량이 강의처럼 변경 되어야 하는데. 처음 truffle 실행할 때와 동일한데 무슨 문제일까요? ㅜ 감사합니다.

답변 0

답변을 작성해보세요.

답변을 기다리고 있는 질문이에요.
첫번째 답변을 남겨보세요!