fixed some payment bugs