Improved commit hook

Now it checks the staged version of the files, not the working copy.