Fixing #518