Refactor send_queued_mail lockfile parameters