fixed #966