statstable.modify( st, 0, [&]( auto& s ) {
   s.supply += quantity;

Here is some code from the eosio.token contract. How can the payer be 0? what does it mean?

Here are the params for the modify function btw (as per developers.eos.io):

modify(itr, payer, updater) where:

  • itr - an iterator pointing to the object to be updated

  • payer - account name of the payer for the Storage usage of the updated row

  • updater - lambda function that updates the target object


This line indicates that passing 0 in the payer argument keeps the existing payer for the entry.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.