add missing return statements