bugs fix with some api