EOSIO / welcome

Documentation that covers EOSIO Overview, Getting Started and Protocol documents
38 stars 54 forks source link

docs: fix "hi" method authorization example #441

Open DanailMinchev opened 3 years ago

DanailMinchev commented 3 years ago

Hi,

Following https://developers.eos.io/welcome/latest/getting-started-guide/hello-world/#authorization example I am receiving:

➜  hello git:(master) ✗ eosio-cpp -abigen -o hello.wasm hello.cpp
/Users/XXX/YYY/contracts/hello/hello.cpp:9:27: error: use of undeclared identifier 'name'
        print( "Hello, ", name{user} );
                          ^
Warning, action <hi> does not have a ricardian contract
1 error generated.
Error while processing /Users/XXX/YYY/contracts/hello/hello.cpp.
abigen error

I tried to fix it, please let me know if it's correct now or I am missing something as I am a beginner in this?

Thanks