close #263 added check for return