TLDR transfer vs transferFrom
Use transfer when when we want to initiate a transfer of tokens from ourselves (us as the function caller) to another address.
Use transferFrom when an external entity is requesting a transfer of tokens from some party A to itself. This is require allowance for the external entity to be set by part A
hence, _spendAllowance will decrement allowance
then, _transfer moves the tokens from A to external entity.
Last updated