Fix NPE
 - amount could be null, but that is not checked