Fixed #797