fix bug in post()