update with the new api
don't mixup integer and double