Fixed invalid parameter after refactoring.