Compatibility with mongoengine 0.8.4