Fixed missing return statement