small api code fix