fixed #547