small changes to the transfer handler