fixed #777