Upgrade to NH 4.0

Hi, I have upgraded to NH 4.0, it is related pull request.