fixed checking of request content type (json)