fixes #7, calling pre restart hook if it exists, and docs