added missing amountOf method