Fixes #1039
Merge pull request #1044 from mdogan/fix/3.2/hibernate

Fixes #1039