fixed mismatch between api and code