Fixes return-nil problem.