Fixed improper module argument assignment on hook registering
Merge pull request #765 from bibich/fixes

Fixed improper module argument assignment on hook registering