fixed an error with getting POST data