resolves #512